home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / tex-k / tex-k-archive.past / tex-k-archive.gz / tex-k-archive / 001001_interran@uluru.Stanford.EDU_Fri Sep 23 21:26:51 1994.msg < prev    next >
Internet Message Format  |  1994-10-11  |  76KB

  1. Received: from uluru.Stanford.EDU by cs.umb.edu with SMTP id AA03166
  2.   (5.65c/IDA-1.4.4 for <tex-k@cs.umb.edu>); Sat, 24 Sep 1994 07:26:53 -0400
  3. Received: by uluru.Stanford.EDU (4.1/inc-1.0)
  4.     id AA17992; Sat, 24 Sep 94 04:26:51 PDT
  5. Date: Sat, 24 Sep 94 04:26:51 PDT
  6. From: interran@uluru.Stanford.EDU (John Interrante)
  7. Message-Id: <9409241126.AA17992@uluru.Stanford.EDU>
  8. To: tex-k@cs.umb.edu
  9. Subject: replacement for web2c.kpathsea.patch
  10.  
  11. Karl Berry asked for volunteers to create a new patch that would
  12. upgrade webc-6.1 to work with kpathsea 2.1.  I really wanted to use
  13. the new run-time configuration file so I could run latex and latex209
  14. side by side more easily.  Fabrice Popineau <popineau@ese-metz.fr>
  15. recently posted an almost complete patch to compile web2c-6.1 with
  16. kpathsea 2.1.  I used it as a starting point (thanks!) and here is the
  17. result.  This patch isn't very well tested and it won't work if Karl
  18. releases new versions of dvipsk and xdvik, but if one or two people
  19. try it and it works for them, Karl probably will replace
  20. web2c.kpathsea.patch with this new patch.
  21.  
  22.         John
  23.  
  24. This file contains some instructions for upgrading web2c-6.1 to use
  25. kpathsea 2.1.  This upgrade is entirely optional and unsupported; you
  26. should apply it only if you really want to use the new features in
  27. kpathsea 2.1 and are willing to fix any problems you may encounter.
  28.  
  29. First, create an empty directory and move into it:
  30.  
  31. % mkdir src
  32. % cd src
  33.  
  34. Fetch the tar files you'll need (web-6.1.tar.gz, web2c-6.1.tar.gz, and
  35. xdvik-18b.tar.gz) from your closest CTAN archive and unpack them
  36. within the current directory on the fly:
  37.  
  38. % ftp ftp.shsu.edu
  39. Connected to pip.SHSU.EDU.
  40. 220 pip.shsu.edu FTP server (Version wu-2.4(4) Thu May 19 15:13:44 CDT 1994) ready.
  41. Name (ftp.shsu.edu:): anonymous
  42. 331 Guest login ok, send your complete e-mail address as password.
  43. Password:
  44. ftp> bin
  45. 200 Type set to I.
  46. ftp> cd /tex-archive/systems/web2c
  47. 250 CWD command successful.
  48. ftp> get web-6.1.tar.gz "| zcat | tar xf -"
  49. 200 PORT command successful.
  50. 150 Opening BINARY mode data connection for web-6.1.tar.gz (1166731 bytes).
  51. 226 Transfer complete.
  52. local: | zcat | tar xf - remote: web-6.1.tar.gz
  53. 1166731 bytes received in 44 seconds (26 Kbytes/s)
  54. ftp> get web2c-6.1.tar.gz "| zcat | tar xf -"
  55. 200 PORT command successful.
  56. 150 Opening BINARY mode data connection for web2c-6.1.tar.gz (658035 bytes).
  57.  
  58. zcat: stdout: Broken pipe
  59. 226 Transfer complete.
  60. local: | zcat | tar xf - remote: web2c-6.1.tar.gz
  61. 658035 bytes received in 41 seconds (16 Kbytes/s)
  62. ftp> cd /tex-archive/dviware/xdvik
  63. 250 CWD command successful.
  64. ftp> get xdvik-18b.tar.gz "| zcat | tar xf -"
  65. 200 PORT command successful.
  66. 150 Opening BINARY mode data connection for xdvik-18b.tar.gz (394691 bytes).
  67. 226 Transfer complete.
  68. local: | zcat | tar xf - remote: xdvik-18b.tar.gz
  69. 394691 bytes received in 25 seconds (15 Kbytes/s)
  70. ftp> quit
  71. 221 Goodbye.
  72. % ls
  73. web2c-6.1   xdvik-18b
  74.  
  75. Throw away everything in web2c-6.1 except the subdirectory web2c and
  76. replace them with the corresponding files from xdvik-18b to create a
  77. new web2c-6.1a that contains kpathsea 2.1:
  78.  
  79. (We throw away web2c/configure because this file would be much larger
  80. if it had to patch the original web2c/configure; patch will just
  81. create web2c/configure from scratch.)
  82.  
  83. % mv web2c-6.1/web2c xdvik-18b
  84. % rm -rf web2c-6.1
  85. % rm -rf xdvik-18b/xdvik
  86. % mv xdvik-18b web2c-6.1a
  87. % rm web2c-6.1a/web2c/configure
  88.  
  89. I created this file by making a symbolic link to the original web2-6.1
  90. directory that I had already updated and running a recursive diff.
  91. These commands are for explanation only; don't type them yourself.
  92.  
  93. % ln -s /path/to/another/web2c-6.1 web2c-6.1b
  94. % diff -Pu2r web2c-6.1a web2c-6.1b > web2c.kpathsea.patch
  95.  
  96. Assuming that you've saved this file in the same directory, here's how
  97. to patch web2c-6.1a:
  98.  
  99. (You should not see any output from patch unless something goes
  100. wrong.)
  101.  
  102. % patch -p -s < web2c.kpathsea.patch
  103.  
  104. You have finished upgrading web2c-6.1 to use kpathsea 2.1.  Now
  105. customize the topmost Makefile.in for your local site and follow the
  106. instructions in web2c/INSTALL to build a new TeX and MF.  I have
  107. already customized the topmost Makefile.in for my local site.  Just
  108. make your own changes if you don't like my customizations.  I also
  109. customized web2c/Makefile.in so it would NOT build a format for latex
  110. since I install latex separately from its own source tree.
  111.  
  112. diff -Pu2r web2c-6.1a/Makefile.in web2c-6.1b/Makefile.in
  113. --- web2c-6.1a/Makefile.in    Mon Sep 12 08:09:55 1994
  114. +++ web2c-6.1b/Makefile.in    Fri Sep 23 21:22:17 1994
  115. @@ -12,4 +12,6 @@
  116.  # if we are to propagate changes at the top level.
  117.  makeargs = $(MFLAGS) CFLAGS='$(CFLAGS)' $(makevars)
  118. +makeargs = $(MFLAGS) CFLAGS='$(CFLAGS)' LDFLAGS='$(LDFLAGS)' LN='$(LN)' \
  119. + $(makevars)
  120.  installargs = INSTALL='$(INSTALL)' INSTALL_DATA='$(INSTALL_DATA)' \
  121.           INSTALL_PROGRAM='$(INSTALL_PROGRAM)' $(makeargs)
  122. @@ -28,4 +30,10 @@
  123.  INSTALL_DATA = @INSTALL_DATA@
  124.  
  125. +# Local site customization.
  126. +CFLAGS = -O
  127. +LDFLAGS = -s
  128. +LN = ln
  129. +INSTALL_DATA = $(INSTALL) -m 444
  130. +install_fonts = false
  131.  
  132.  # Make the library before the programs.
  133. diff -Pu2r web2c-6.1a/kpathsea/tex-file.c web2c-6.1b/kpathsea/tex-file.c
  134. --- web2c-6.1a/kpathsea/tex-file.c    Fri Aug 26 06:07:20 1994
  135. +++ web2c-6.1b/kpathsea/tex-file.c    Fri Sep 23 15:28:58 1994
  136. @@ -175,4 +175,5 @@
  137.        break;
  138.      case kpse_any_glyph_format:
  139. +      INIT_MT ("MakeTeXPK", MAKETEXPK_SPEC);
  140.        INIT_FORMAT ("bitmap", true, DEFAULT_GLYPHFONTS, KPSE_GLYPH_ENVS);
  141.        FMT_INFO.suffix_search_only = true;
  142. diff -Pu2r web2c-6.1a/kpathsea/tex-file.h web2c-6.1b/kpathsea/tex-file.h
  143. --- web2c-6.1a/kpathsea/tex-file.h    Thu Aug 25 14:36:10 1994
  144. +++ web2c-6.1b/kpathsea/tex-file.h    Fri Sep 23 14:03:10 1994
  145. @@ -60,5 +60,5 @@
  146.    kpse_dvips_config_format,
  147.    kpse_dvips_header_format,
  148. -  kpse_last_format = kpse_dvips_header_format
  149. +  kpse_last_format
  150.  } kpse_file_format_type;
  151.  
  152. diff -Pu2r web2c-6.1a/web2c/Makefile.in web2c-6.1b/web2c/Makefile.in
  153. --- web2c-6.1a/web2c/Makefile.in    Thu Feb  3 04:47:59 1994
  154. +++ web2c-6.1b/web2c/Makefile.in    Fri Sep 23 23:45:44 1994
  155. @@ -76,4 +76,5 @@
  156.  bases = mf.base cmmf.base
  157.  fmts = tex.fmt latex.fmt 
  158. +fmts = tex.fmt
  159.  # slitex.fmt etex.fmt amslatex.fmt amstex.fmt texinfo.fmt inrstex.fmt
  160.  # picplus.fmt
  161. @@ -125,7 +126,7 @@
  162.  # wlibs is substituted by web2c's configure, LIBS by general configure
  163.  # routines, and the others by AC_FIND_XTRA.
  164. -x_include_flags = @x_include_flags@
  165. -x_lib_flags = @x_lib_flags@
  166. -x_extra_libs = @x_extra_libs@
  167. +x_include_flags = @X_CFLAGS@
  168. +x_lib_flags = @X_LIBS@
  169. +x_extra_libs = @X_EXTRA_LIBS@
  170.  wlibs = @wlibs@
  171.  LIBS = @LIBS@ $(extralibs)
  172. diff -Pu2r web2c-6.1a/web2c/configure.in web2c-6.1b/web2c/configure.in
  173. --- web2c-6.1a/web2c/configure.in    Tue Feb  1 14:42:20 1994
  174. +++ web2c-6.1b/web2c/configure.in    Sat Sep 24 02:49:41 1994
  175. @@ -33,5 +33,5 @@
  176.  dnl Must do this last, as the addition to DEFS in Autoconf 1.3 confuses
  177.  dnl the compiler.
  178. -AC_DECLARE_YYTEXT
  179. +AC_YYTEXT_POINTER
  180.  
  181.  echo checking for window system libraries
  182. @@ -47,8 +47,5 @@
  183.    AC_FIND_X
  184.    AC_FIND_XTRA
  185. -  if test -z "$Xextlib"; then
  186. -    AC_HAVE_LIBRARY(Xext, Xextlib=-lXext)
  187. -  fi
  188. -  wlibs="-lXt $Xextlib -lX11 $wlibs"
  189. +  wlibs="-lXt $X_EXTRA_LIBS -lX11 $wlibs"
  190.    (cd $srcdir/mf/MFwindow; rm -f x11.c; $LN_S x11-Xt.c x11.c)
  191.  fi
  192. diff -Pu2r web2c-6.1a/web2c/configure web2c-6.1b/web2c/configure
  193. --- web2c-6.1a/web2c/configure    Wed Dec 31 16:00:00 1969
  194. +++ web2c-6.1b/web2c/configure    Sat Sep 24 02:49:42 1994
  195. @@ -0,0 +1,2068 @@
  196. +#!/bin/sh
  197. +# Guess values for system-dependent variables and create Makefiles.
  198. +# Generated automatically using autoconf version 1.11 
  199. +# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
  200. +
  201. +# This configure script is free software; you can redistribute it and/or
  202. +# modify it under the terms of the GNU General Public License as published
  203. +# by the Free Software Foundation; either version 2, or (at your option)
  204. +# any later version.
  205. +
  206. +# This script is distributed in the hope that it will be useful, but
  207. +# WITHOUT ANY WARRANTY; without even the implied warranty of
  208. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General
  209. +# Public License for more details.
  210. +
  211. +# You should have received a copy of the GNU General Public License
  212. +# along with this program; if not, write to the Free Software
  213. +# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  214. +
  215. +# Save the original args to write them into config.status later.
  216. +configure_args="$*"
  217. +
  218. +# Only options that might do something get documented.
  219. +ac_usage="Usage: configure [options] [host]
  220. +Options: [defaults in brackets after descriptions]
  221. +--build=BUILD        configure for building on BUILD [BUILD=HOST]
  222. +--disable-FEATURE    do not include FEATURE (same as --enable-FEATURE=no)
  223. +--enable-FEATURE[=ARG]    include FEATURE [ARG=yes]
  224. +--exec-prefix=PREFIX    install host dependent files in PREFIX [/usr/local]
  225. +--help            print this message
  226. +--host=HOST        configure for HOST [guessed]
  227. +--prefix=PREFIX        install host independent files in PREFIX [/usr/local]
  228. +--quiet, --silent    do not print \`checking for...' messages
  229. +--srcdir=DIR        find the sources in DIR [configure dir or ..]
  230. +--target=TARGET        configure for TARGET [TARGET=HOST]
  231. +--verbose        print results of checks
  232. +--version        print the version of autoconf that created configure
  233. +--with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  234. +--without-PACKAGE    do not use PACKAGE (same as --with-PACKAGE=no)
  235. +--x-includes=DIR    X include files are in DIR
  236. +--x-libraries=DIR    X library files are in DIR"
  237. +
  238. +# Initialize some variables set by options.
  239. +# The variables have the same names as the options, with
  240. +# dashes changed to underlines.
  241. +build=NONE
  242. +exec_prefix=
  243. +host=NONE
  244. +no_create=
  245. +nonopt=NONE
  246. +norecursion=
  247. +prefix=
  248. +program_prefix=
  249. +program_suffix=
  250. +program_transform_name=
  251. +silent=
  252. +srcdir=
  253. +target=NONE
  254. +verbose=
  255. +x_includes=
  256. +x_libraries=
  257. +
  258. +ac_prev=
  259. +for ac_option
  260. +do
  261. +
  262. +  # If the previous option needs an argument, assign it.
  263. +  if test -n "$ac_prev"; then
  264. +    eval "$ac_prev=\$ac_option"
  265. +    ac_prev=
  266. +    continue
  267. +  fi
  268. +
  269. +  # Accept (but ignore some of) the important Cygnus configure
  270. +  # options, so we can diagnose typos.
  271. +
  272. +  case "$ac_option" in
  273. +  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  274. +  *) ac_optarg= ;;
  275. +  esac
  276. +
  277. +  case "$ac_option" in
  278. +
  279. +  -build | --build | --buil | --bui | --bu | --b)
  280. +    ac_prev=build ;;
  281. +  -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  282. +    build="$ac_optarg" ;;
  283. +
  284. +  -disable-* | --disable-*)
  285. +    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  286. +    # Reject names that aren't valid shell variable names.
  287. +    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  288. +      echo "configure: $ac_feature: invalid feature name" >&2; exit 1
  289. +    fi
  290. +    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  291. +    eval "enable_${ac_feature}=no" ;;
  292. +
  293. +  -enable-* | --enable-*)
  294. +    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  295. +    # Reject names that aren't valid shell variable names.
  296. +    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  297. +      echo "configure: $ac_feature: invalid feature name" >&2; exit 1
  298. +    fi
  299. +    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  300. +    case "$ac_option" in
  301. +      *=*) ;;
  302. +      *) ac_optarg=yes ;;
  303. +    esac
  304. +    eval "enable_${ac_feature}='$ac_optarg'" ;;
  305. +
  306. +  # For backward compatibility, recognize -exec-prefix and --exec_prefix.
  307. +  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  308. +  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  309. +  | --exec | --exe | --ex)
  310. +    ac_prev=exec_prefix ;;
  311. +  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  312. +  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  313. +  | --exec=* | --exe=* | --ex=*)
  314. +    exec_prefix="$ac_optarg" ;;
  315. +
  316. +  -gas | --gas | --ga | --g)
  317. +    with_gas=yes ;; # Obsolete; use --with-gas.
  318. +
  319. +  -help | --help | --hel | --he)
  320. +    cat << EOF
  321. +$ac_usage
  322. +EOF
  323. +    exit 0 ;;
  324. +
  325. +  -host | --host | --hos | --ho)
  326. +    ac_prev=host ;;
  327. +  -host=* | --host=* | --hos=* | --ho=*)
  328. +    host="$ac_optarg" ;;
  329. +
  330. +  -nfp | --nfp | --nf)
  331. +    with_fp=no ;; # Obsolete; use --without-fp.
  332. +
  333. +  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  334. +  | --no-cr | --no-c)
  335. +    no_create=yes ;;
  336. +
  337. +  -norecursion | --norecursion | --norecursio | --norecursi \
  338. +  | --norecurs | --norecur | --norecu | --norec | --nore | --nor)
  339. +    norecursion=yes ;;
  340. +
  341. +  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  342. +    ac_prev=prefix ;;
  343. +  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  344. +    prefix="$ac_optarg" ;;
  345. +
  346. +  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  347. +  | --program-pre | --program-pr | --program-p)
  348. +    ac_prev=program_prefix ;;
  349. +  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  350. +  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  351. +    program_prefix="$ac_optarg" ;;
  352. +
  353. +  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  354. +  | --program-suf | --program-su | --program-s)
  355. +    ac_prev=program_suffix ;;
  356. +  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  357. +  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  358. +    program_suffix="$ac_optarg" ;;
  359. +
  360. +  -program-transform-name | --program-transform-name \
  361. +  | --program-transform-nam | --program-transform-na \
  362. +  | --program-transform-n | --program-transform- \
  363. +  | --program-transform | --program-transfor \
  364. +  | --program-transfo | --program-transf \
  365. +  | --program-trans | --program-tran \
  366. +  | --progr-tra | --program-tr | --program-t)
  367. +    ac_prev=program_transform_name ;;
  368. +  -program-transform-name=* | --program-transform-name=* \
  369. +  | --program-transform-nam=* | --program-transform-na=* \
  370. +  | --program-transform-n=* | --program-transform-=* \
  371. +  | --program-transform=* | --program-transfor=* \
  372. +  | --program-transfo=* | --program-transf=* \
  373. +  | --program-trans=* | --program-tran=* \
  374. +  | --progr-tra=* | --program-tr=* | --program-t=*)
  375. +    program_transform_name="$ac_optarg" ;;
  376. +
  377. +  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  378. +  | -silent | --silent | --silen | --sile | --sil)
  379. +    silent=yes ;;
  380. +
  381. +  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  382. +    ac_prev=srcdir ;;
  383. +  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  384. +    srcdir="$ac_optarg" ;;
  385. +
  386. +  -target | --target | --targe | --targ | --tar | --ta | --t)
  387. +    ac_prev=target ;;
  388. +  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  389. +    target="$ac_optarg" ;;
  390. +
  391. +  -v | -verbose | --verbose | --verbos | --verbo | --verb)
  392. +    verbose=yes ;;
  393. +
  394. +  -version | --version | --versio | --versi | --vers)
  395. +    echo "configure generated by autoconf version 1.11"
  396. +    exit 0 ;;
  397. +
  398. +  -with-* | --with-*)
  399. +    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  400. +    # Reject names that aren't valid shell variable names.
  401. +    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  402. +      echo "configure: $ac_package: invalid package name" >&2; exit 1
  403. +    fi
  404. +    ac_package=`echo $ac_package| sed 's/-/_/g'`
  405. +    case "$ac_option" in
  406. +      *=*) ;;
  407. +      *) ac_optarg=yes ;;
  408. +    esac
  409. +    eval "with_${ac_package}='$ac_optarg'" ;;
  410. +
  411. +  -without-* | --without-*)
  412. +    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  413. +    # Reject names that aren't valid shell variable names.
  414. +    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  415. +      echo "configure: $ac_package: invalid package name" >&2; exit 1
  416. +    fi
  417. +    ac_package=`echo $ac_package| sed 's/-/_/g'`
  418. +    eval "with_${ac_package}=no" ;;
  419. +
  420. +  --x) with_x=yes ;; # Obsolete; use --with-x.
  421. +
  422. +  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  423. +  | --x-incl | --x-inc | --x-in | --x-i)
  424. +    ac_prev=x_includes ;;
  425. +  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  426. +  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  427. +    x_includes="$ac_optarg" ;;
  428. +
  429. +  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  430. +  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  431. +    ac_prev=x_libraries ;;
  432. +  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  433. +  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  434. +    x_libraries="$ac_optarg" ;;
  435. +
  436. +  -*) echo "configure: $ac_option: invalid option; use --help to show usage" >&2; exit 1
  437. +    ;;
  438. +
  439. +  *) 
  440. +    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  441. +      echo "configure: warning: $ac_option: invalid host type" >&2
  442. +    fi
  443. +    if test "x$nonopt" != xNONE; then
  444. +      echo "configure: can only configure for one host and one target at a time" >&2; exit 1
  445. +    fi
  446. +    nonopt="$ac_option"
  447. +    ;;
  448. +
  449. +  esac
  450. +done
  451. +
  452. +if test -n "$ac_prev"; then
  453. +  echo "configure: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" >&2; exit 1
  454. +fi
  455. +
  456. +trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
  457. +trap 'rm -fr confdefs* $ac_clean_files' 0
  458. +
  459. +# Save the original args if we used an alternate arg parser.
  460. +ac_configure_temp="${configure_args-$*}"
  461. +# Strip out --no-create and --norecursion so they don't pile up.
  462. +configure_args=
  463. +for ac_arg in $ac_configure_temp; do
  464. +  case "$ac_arg" in
  465. +  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  466. +  | --no-cr | --no-c) ;;
  467. +  -norecursion | --norecursion | --norecursio | --norecursi \
  468. +  | --norecurs | --norecur | --norecu | --norec | --nore | --nor) ;;
  469. +  *) configure_args="$configure_args $ac_arg" ;;
  470. +  esac
  471. +done
  472. +
  473. +# NLS nuisances.
  474. +# These must not be set unconditionally because not all systems understand
  475. +# e.g. LANG=C (notably SCO).
  476. +if test "${LC_ALL+set}" = 'set'; then LC_ALL=C; export LC_ALL; fi
  477. +if test "${LANG+set}"   = 'set'; then LANG=C;   export LANG;   fi
  478. +
  479. +# confdefs.h avoids OS command line length limits that DEFS can exceed.
  480. +rm -rf conftest* confdefs.h
  481. +# AIX cpp loses on an empty file, so make sure it contains at least a newline.
  482. +echo > confdefs.h
  483. +
  484. +# A filename unique to this package, relative to the directory that
  485. +# configure is in, which we can look for to find out if srcdir is correct.
  486. +ac_unique_file=web2c/web2c.c
  487. +
  488. +# Find the source files, if location was not specified.
  489. +if test -z "$srcdir"; then
  490. +  ac_srcdir_defaulted=yes
  491. +  # Try the directory containing this script, then `..'.
  492. +  ac_prog=$0
  493. +  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  494. +  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  495. +  srcdir=$ac_confdir
  496. +  if test ! -r $srcdir/$ac_unique_file; then
  497. +    srcdir=..
  498. +  fi
  499. +fi
  500. +if test ! -r $srcdir/$ac_unique_file; then
  501. +  if test x$ac_srcdir_defaulted = xyes; then
  502. +    echo "configure: can not find sources in ${ac_confdir} or .." >&2; exit 1
  503. +  else
  504. +    echo "configure: can not find sources in ${srcdir}" >&2; exit 1
  505. +  fi
  506. +fi
  507. +ac_ext=c
  508. +# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  509. +ac_cpp='${CPP}'
  510. +ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS >/dev/null 2>&1'
  511. +
  512. +
  513. +
  514. +
  515. +
  516. +
  517. +
  518. +
  519. +
  520. +if test -z "$CC"; then
  521. +  # Extract the first word of `gcc', so it can be a program name with args.
  522. +  set ac_dummy gcc; ac_word=$2
  523. +  test -n "$silent" || echo "checking for $ac_word"
  524. +  IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  525. +  for ac_dir in $PATH; do
  526. +    test -z "$ac_dir" && ac_dir=.
  527. +    if test -f $ac_dir/$ac_word; then
  528. +      CC="gcc"
  529. +      break
  530. +    fi
  531. +  done
  532. +  IFS="$ac_save_ifs"
  533. +fi
  534. +test -z "$CC" && CC="cc"
  535. +test -n "$CC" && test -n "$verbose" && echo "    setting CC to $CC"
  536. +
  537. +# Find out if we are using GNU C, under whatever name.
  538. +cat > conftest.c <<EOF
  539. +#ifdef __GNUC__
  540. +  yes
  541. +#endif
  542. +EOF
  543. +${CC-cc} -E conftest.c > conftest.out 2>&1
  544. +if egrep yes conftest.out >/dev/null 2>&1; then
  545. +  GCC=1 # For later tests.
  546. +fi
  547. +rm -f conftest*
  548. +
  549. +test -n "$silent" || echo "checking how to run the C preprocessor"
  550. +if test -z "$CPP"; then
  551. +  # This must be in double quotes, not single quotes, because CPP may get
  552. +  # substituted into the Makefile and ``${CC-cc}'' will simply confuse
  553. +  # make.  It must be expanded now.
  554. +  CPP="${CC-cc} -E"
  555. +  cat > conftest.${ac_ext} <<EOF
  556. +#include "confdefs.h"
  557. +#include <stdio.h>
  558. +Syntax Error
  559. +EOF
  560. +# Some shells (Coherent) do redirections in the wrong order, so need
  561. +# the parens.
  562. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  563. +if test -z "$ac_err"; then
  564. +  :
  565. +else
  566. +  rm -rf conftest*
  567. +  CPP="${CC-cc} -E -traditional-cpp"
  568. +  cat > conftest.${ac_ext} <<EOF
  569. +#include "confdefs.h"
  570. +#include <stdio.h>
  571. +Syntax Error
  572. +EOF
  573. +# Some shells (Coherent) do redirections in the wrong order, so need
  574. +# the parens.
  575. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  576. +if test -z "$ac_err"; then
  577. +  :
  578. +else
  579. +  rm -rf conftest*
  580. +  CPP=/lib/cpp
  581. +fi
  582. +rm -f conftest*
  583. +fi
  584. +rm -f conftest*
  585. +fi
  586. +test -n "$verbose" && echo "    setting CPP to $CPP"
  587. +
  588. +# Make sure to not get the incompatible SysV /etc/install and
  589. +# /usr/sbin/install, which might be in PATH before a BSD-like install,
  590. +# or the SunOS /usr/etc/install directory, or the AIX /bin/install,
  591. +# or the AFS install, which mishandles nonexistent args, or
  592. +# /usr/ucb/install on SVR4, which tries to use the nonexistent group
  593. +# `staff', or /sbin/install on IRIX which has incompatible command-line
  594. +# syntax.  Sigh.
  595. +#
  596. +#     On most BSDish systems install is in /usr/bin, not /usr/ucb
  597. +#     anyway.
  598. +# This turns out not to be true, so the mere pathname isn't an indication
  599. +# of whether the program works.  What we really need is a set of tests for
  600. +# the install program to see if it actually works in all the required ways.
  601. +#
  602. +# Avoid using ./install, which might have been erroneously created
  603. +# by make from ./install.sh.
  604. +if test -z "${INSTALL}"; then
  605. +  test -n "$silent" || echo "checking for a BSD compatible install"
  606. +  IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  607. +  for ac_dir in $PATH; do
  608. +    case "$ac_dir" in
  609. +    ''|.|/etc|/sbin|/usr/sbin|/usr/etc|/usr/afsws/bin|/usr/ucb) ;;
  610. +    *)
  611. +      # OSF1 and SCO ODT 3.0 have their own names for install.
  612. +      for ac_prog in installbsd scoinst install; do
  613. +        if test -f $ac_dir/$ac_prog; then
  614. +      if test $ac_prog = install &&
  615. +            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  616. +        # AIX install.  It has an incompatible calling convention.
  617. +        # OSF/1 installbsd also uses dspmsg, but is usable.
  618. +        :
  619. +      else
  620. +        INSTALL="$ac_dir/$ac_prog -c"
  621. +        break 2
  622. +      fi
  623. +    fi
  624. +      done
  625. +      ;;
  626. +    esac
  627. +  done
  628. +  IFS="$ac_save_ifs"
  629. +fi
  630. +
  631. +if test -z "$INSTALL"; then
  632. +  # As a last resort, use the slow shell script.
  633. +  for ac_dir in ${srcdir} ${srcdir}/.. ${srcdir}/../..; do
  634. +    if test -f $ac_dir/install.sh; then
  635. +      INSTALL="$ac_dir/install.sh -c"; break
  636. +    fi
  637. +  done
  638. +fi
  639. +if test -z "$INSTALL"; then
  640. +  echo "configure: can not find install.sh in ${srcdir} or ${srcdir}/.. or ${srcdir}/../.." >&2; exit 1
  641. +fi
  642. +test -n "$verbose" && echo "    setting INSTALL to $INSTALL"
  643. +
  644. +# Use test -z because SunOS4 sh mishandles ${INSTALL_PROGRAM-'${INSTALL}'}.
  645. +# It thinks the first close brace ends the variable substitution.
  646. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  647. +test -n "$verbose" && echo "    setting INSTALL_PROGRAM to $INSTALL_PROGRAM"
  648. +
  649. +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  650. +test -n "$verbose" && echo "    setting INSTALL_DATA to $INSTALL_DATA"
  651. +
  652. +if test -z "$RANLIB"; then
  653. +  # Extract the first word of `ranlib', so it can be a program name with args.
  654. +  set ac_dummy ranlib; ac_word=$2
  655. +  test -n "$silent" || echo "checking for $ac_word"
  656. +  IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  657. +  for ac_dir in $PATH; do
  658. +    test -z "$ac_dir" && ac_dir=.
  659. +    if test -f $ac_dir/$ac_word; then
  660. +      RANLIB="ranlib"
  661. +      break
  662. +    fi
  663. +  done
  664. +  IFS="$ac_save_ifs"
  665. +fi
  666. +test -z "$RANLIB" && RANLIB=":"
  667. +test -n "$RANLIB" && test -n "$verbose" && echo "    setting RANLIB to $RANLIB"
  668. +
  669. +
  670. +test -n "$silent" || echo "checking for POSIXized ISC"
  671. +if test -d /etc/conf/kconfig.d &&
  672. +  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
  673. +then
  674. +  ISC=1 # If later tests want to check for ISC.
  675. +  
  676. +{
  677. +test -n "$verbose" && \
  678. +echo "    defining _POSIX_SOURCE"
  679. +echo "#define" _POSIX_SOURCE "1" >> confdefs.h
  680. +DEFS="$DEFS -D_POSIX_SOURCE=1"
  681. +ac_sed_defs="${ac_sed_defs}\${ac_dA}_POSIX_SOURCE\${ac_dB}_POSIX_SOURCE\${ac_dC}1\${ac_dD}
  682. +\${ac_uA}_POSIX_SOURCE\${ac_uB}_POSIX_SOURCE\${ac_uC}1\${ac_uD}
  683. +\${ac_eA}_POSIX_SOURCE\${ac_eB}_POSIX_SOURCE\${ac_eC}1\${ac_eD}
  684. +"
  685. +}
  686. +
  687. +  if test -n "$GCC"; then
  688. +    CC="$CC -posix"
  689. +  else
  690. +    CC="$CC -Xp"
  691. +  fi
  692. +fi
  693. +
  694. +
  695. +test -n "$silent" || echo "checking for directory library header"
  696. +ac_dir_header=
  697. +if test -z "$ac_dir_header"; then
  698. +  test -n "$silent" || echo "checking for dirent.h"
  699. +cat > conftest.${ac_ext} <<EOF
  700. +#include "confdefs.h"
  701. +#include <sys/types.h>
  702. +#include <dirent.h>
  703. +int main() { return 0; }
  704. +int t() { DIR *dirp = 0;; return 0; }
  705. +EOF
  706. +if eval $ac_compile; then
  707. +  rm -rf conftest*
  708. +  
  709. +{
  710. +test -n "$verbose" && \
  711. +echo "    defining DIRENT"
  712. +echo "#define" DIRENT "1" >> confdefs.h
  713. +DEFS="$DEFS -DDIRENT=1"
  714. +ac_sed_defs="${ac_sed_defs}\${ac_dA}DIRENT\${ac_dB}DIRENT\${ac_dC}1\${ac_dD}
  715. +\${ac_uA}DIRENT\${ac_uB}DIRENT\${ac_uC}1\${ac_uD}
  716. +\${ac_eA}DIRENT\${ac_eB}DIRENT\${ac_eC}1\${ac_eD}
  717. +"
  718. +}
  719. + ac_dir_header=dirent.h
  720. +
  721. +fi
  722. +rm -f conftest*
  723. +fi
  724. +if test -z "$ac_dir_header"; then
  725. +  test -n "$silent" || echo "checking for sys/ndir.h"
  726. +cat > conftest.${ac_ext} <<EOF
  727. +#include "confdefs.h"
  728. +#include <sys/types.h>
  729. +#include <sys/ndir.h>
  730. +int main() { return 0; }
  731. +int t() { DIR *dirp = 0;; return 0; }
  732. +EOF
  733. +if eval $ac_compile; then
  734. +  rm -rf conftest*
  735. +  
  736. +{
  737. +test -n "$verbose" && \
  738. +echo "    defining SYSNDIR"
  739. +echo "#define" SYSNDIR "1" >> confdefs.h
  740. +DEFS="$DEFS -DSYSNDIR=1"
  741. +ac_sed_defs="${ac_sed_defs}\${ac_dA}SYSNDIR\${ac_dB}SYSNDIR\${ac_dC}1\${ac_dD}
  742. +\${ac_uA}SYSNDIR\${ac_uB}SYSNDIR\${ac_uC}1\${ac_uD}
  743. +\${ac_eA}SYSNDIR\${ac_eB}SYSNDIR\${ac_eC}1\${ac_eD}
  744. +"
  745. +}
  746. + ac_dir_header=sys/ndir.h
  747. +
  748. +fi
  749. +rm -f conftest*
  750. +fi
  751. +if test -z "$ac_dir_header"; then
  752. +  test -n "$silent" || echo "checking for sys/dir.h"
  753. +cat > conftest.${ac_ext} <<EOF
  754. +#include "confdefs.h"
  755. +#include <sys/types.h>
  756. +#include <sys/dir.h>
  757. +int main() { return 0; }
  758. +int t() { DIR *dirp = 0;; return 0; }
  759. +EOF
  760. +if eval $ac_compile; then
  761. +  rm -rf conftest*
  762. +  
  763. +{
  764. +test -n "$verbose" && \
  765. +echo "    defining SYSDIR"
  766. +echo "#define" SYSDIR "1" >> confdefs.h
  767. +DEFS="$DEFS -DSYSDIR=1"
  768. +ac_sed_defs="${ac_sed_defs}\${ac_dA}SYSDIR\${ac_dB}SYSDIR\${ac_dC}1\${ac_dD}
  769. +\${ac_uA}SYSDIR\${ac_uB}SYSDIR\${ac_uC}1\${ac_uD}
  770. +\${ac_eA}SYSDIR\${ac_eB}SYSDIR\${ac_eC}1\${ac_eD}
  771. +"
  772. +}
  773. + ac_dir_header=sys/dir.h
  774. +
  775. +fi
  776. +rm -f conftest*
  777. +fi
  778. +if test -z "$ac_dir_header"; then
  779. +  test -n "$silent" || echo "checking for ndir.h"
  780. +cat > conftest.${ac_ext} <<EOF
  781. +#include "confdefs.h"
  782. +#include <sys/types.h>
  783. +#include <ndir.h>
  784. +int main() { return 0; }
  785. +int t() { DIR *dirp = 0;; return 0; }
  786. +EOF
  787. +if eval $ac_compile; then
  788. +  rm -rf conftest*
  789. +  
  790. +{
  791. +test -n "$verbose" && \
  792. +echo "    defining NDIR"
  793. +echo "#define" NDIR "1" >> confdefs.h
  794. +DEFS="$DEFS -DNDIR=1"
  795. +ac_sed_defs="${ac_sed_defs}\${ac_dA}NDIR\${ac_dB}NDIR\${ac_dC}1\${ac_dD}
  796. +\${ac_uA}NDIR\${ac_uB}NDIR\${ac_uC}1\${ac_uD}
  797. +\${ac_eA}NDIR\${ac_eB}NDIR\${ac_eC}1\${ac_eD}
  798. +"
  799. +}
  800. + ac_dir_header=ndir.h
  801. +
  802. +fi
  803. +rm -f conftest*
  804. +fi
  805. +
  806. +test -n "$silent" || echo "checking for closedir return value"
  807. +cat > conftest.${ac_ext} <<EOF
  808. +#include "confdefs.h"
  809. +#include <sys/types.h>
  810. +#include <$ac_dir_header>
  811. +int closedir(); main() { exit(closedir(opendir(".")) != 0); }
  812. +EOF
  813. +eval $ac_compile
  814. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  815. +  :
  816. +else
  817. +  
  818. +{
  819. +test -n "$verbose" && \
  820. +echo "    defining VOID_CLOSEDIR"
  821. +echo "#define" VOID_CLOSEDIR "1" >> confdefs.h
  822. +DEFS="$DEFS -DVOID_CLOSEDIR=1"
  823. +ac_sed_defs="${ac_sed_defs}\${ac_dA}VOID_CLOSEDIR\${ac_dB}VOID_CLOSEDIR\${ac_dC}1\${ac_dD}
  824. +\${ac_uA}VOID_CLOSEDIR\${ac_uB}VOID_CLOSEDIR\${ac_uC}1\${ac_uD}
  825. +\${ac_eA}VOID_CLOSEDIR\${ac_eB}VOID_CLOSEDIR\${ac_eC}1\${ac_eD}
  826. +"
  827. +}
  828. +
  829. +fi
  830. +rm -fr conftest*
  831. +
  832. +test -n "$silent" || echo "checking for Xenix"
  833. +cat > conftest.${ac_ext} <<EOF
  834. +#include "confdefs.h"
  835. +#if defined(M_XENIX) && !defined(M_UNIX)
  836. +  yes
  837. +#endif
  838. +
  839. +EOF
  840. +eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1"
  841. +if egrep "yes" conftest.out >/dev/null 2>&1; then
  842. +  rm -rf conftest*
  843. +  XENIX=1
  844. +
  845. +fi
  846. +rm -f conftest*
  847. +
  848. +if test -n "$XENIX"; then
  849. +  LIBS="$LIBS -lx"
  850. +  case "$DEFS" in
  851. +  *SYSNDIR*) ;;
  852. +  *) LIBS="-ldir $LIBS" ;; # Make sure -ldir precedes any -lx.
  853. +  esac
  854. +fi
  855. +
  856. +test -n "$silent" || echo "checking for ANSI C header files"
  857. +cat > conftest.${ac_ext} <<EOF
  858. +#include "confdefs.h"
  859. +#include <stdlib.h>
  860. +#include <stdarg.h>
  861. +#include <string.h>
  862. +#include <float.h>
  863. +EOF
  864. +# Some shells (Coherent) do redirections in the wrong order, so need
  865. +# the parens.
  866. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  867. +if test -z "$ac_err"; then
  868. +  rm -rf conftest*
  869. +  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  870. +echo '#include "confdefs.h"
  871. +#include <string.h>' > conftest.${ac_ext}
  872. +eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1"
  873. +if egrep "memchr" conftest.out >/dev/null 2>&1; then
  874. +  rm -rf conftest*
  875. +  # SGI's /bin/cc from Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  876. +cat > conftest.${ac_ext} <<EOF
  877. +#include "confdefs.h"
  878. +#include <ctype.h>
  879. +#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  880. +#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  881. +#define XOR(e,f) (((e) && !(f)) || (!(e) && (f)))
  882. +int main () { int i; for (i = 0; i < 256; i++)
  883. +if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
  884. +exit (0); }
  885. +
  886. +EOF
  887. +eval $ac_compile
  888. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  889. +  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  890. +echo '#include "confdefs.h"
  891. +#include <stdlib.h>' > conftest.${ac_ext}
  892. +eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1"
  893. +if egrep "free" conftest.out >/dev/null 2>&1; then
  894. +  rm -rf conftest*
  895. +  
  896. +{
  897. +test -n "$verbose" && \
  898. +echo "    defining STDC_HEADERS"
  899. +echo "#define" STDC_HEADERS "1" >> confdefs.h
  900. +DEFS="$DEFS -DSTDC_HEADERS=1"
  901. +ac_sed_defs="${ac_sed_defs}\${ac_dA}STDC_HEADERS\${ac_dB}STDC_HEADERS\${ac_dC}1\${ac_dD}
  902. +\${ac_uA}STDC_HEADERS\${ac_uB}STDC_HEADERS\${ac_uC}1\${ac_uD}
  903. +\${ac_eA}STDC_HEADERS\${ac_eB}STDC_HEADERS\${ac_eC}1\${ac_eD}
  904. +"
  905. +}
  906. +
  907. +
  908. +fi
  909. +rm -f conftest*
  910. +
  911. +
  912. +fi
  913. +rm -fr conftest*
  914. +
  915. +fi
  916. +rm -f conftest*
  917. +
  918. +
  919. +fi
  920. +rm -f conftest*
  921. +
  922. +for ac_hdr in assert.h float.h limits.h memory.h pwd.h stdlib.h \
  923. +                string.h unistd.h
  924. +do
  925. +ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'`
  926. +test -n "$silent" || echo "checking for ${ac_hdr}"
  927. +cat > conftest.${ac_ext} <<EOF
  928. +#include "confdefs.h"
  929. +#include <${ac_hdr}>
  930. +EOF
  931. +# Some shells (Coherent) do redirections in the wrong order, so need
  932. +# the parens.
  933. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  934. +if test -z "$ac_err"; then
  935. +  rm -rf conftest*
  936. +  
  937. +{
  938. +test -n "$verbose" && \
  939. +echo "    defining ${ac_tr_hdr}"
  940. +echo "#define" ${ac_tr_hdr} "1" >> confdefs.h
  941. +DEFS="$DEFS -D${ac_tr_hdr}=1"
  942. +ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD}
  943. +\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD}
  944. +\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD}
  945. +"
  946. +}
  947. +
  948. +
  949. +fi
  950. +rm -f conftest*
  951. +done
  952. +
  953. +
  954. +for ac_func in bcopy memmove putenv
  955. +do
  956. +ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'`
  957. +test -n "$silent" || echo "checking for ${ac_func}"
  958. +cat > conftest.${ac_ext} <<EOF
  959. +#include "confdefs.h"
  960. +#include <ctype.h>
  961. +int main() { return 0; }
  962. +int t() { 
  963. +/* The GNU C library defines this for functions which it implements
  964. +    to always fail with ENOSYS.  Some functions are actually named
  965. +    something starting with __ and the normal name is an alias.  */
  966. +#if defined (__stub_${ac_func}) || defined (__stub___${ac_func})
  967. +choke me
  968. +#else
  969. +/* Override any gcc2 internal prototype to avoid an error.  */
  970. +extern char ${ac_func}(); ${ac_func}();
  971. +#endif
  972. +; return 0; }
  973. +EOF
  974. +if eval $ac_compile; then
  975. +  rm -rf conftest*
  976. +  {
  977. +test -n "$verbose" && \
  978. +echo "    defining ${ac_tr_func}"
  979. +echo "#define" ${ac_tr_func} "1" >> confdefs.h
  980. +DEFS="$DEFS -D${ac_tr_func}=1"
  981. +ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_func}\${ac_dB}${ac_tr_func}\${ac_dC}1\${ac_dD}
  982. +\${ac_uA}${ac_tr_func}\${ac_uB}${ac_tr_func}\${ac_uC}1\${ac_uD}
  983. +\${ac_eA}${ac_tr_func}\${ac_eB}${ac_tr_func}\${ac_eC}1\${ac_eD}
  984. +"
  985. +}
  986. +
  987. +
  988. +fi
  989. +rm -f conftest*
  990. +done
  991. +
  992. +ac_prog='/* Ultrix mips cc rejects this.  */
  993. +typedef int charset[2]; const charset x;
  994. +/* SunOS 4.1.1 cc rejects this.  */
  995. +char const *const *ccp;
  996. +char **p;
  997. +/* AIX XL C 1.02.0.0 rejects this.
  998. +   It does not let you subtract one const X* pointer from another in an arm
  999. +   of an if-expression whose if-part is not a constant expression */
  1000. +const char *g = "string";
  1001. +ccp = &g + (g ? g-g : 0);
  1002. +/* HPUX 7.0 cc rejects these. */
  1003. +++ccp;
  1004. +p = (char**) ccp;
  1005. +ccp = (char const *const *) p;
  1006. +{ /* SCO 3.2v4 cc rejects this.  */
  1007. +  char *t;
  1008. +  char const *s = 0 ? (char *) 0 : (char const *) 0;
  1009. +
  1010. +  *t++ = 0;
  1011. +}
  1012. +{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  1013. +  int x[] = {25,17};
  1014. +  const int *foo = &x[0];
  1015. +  ++foo;
  1016. +}
  1017. +{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  1018. +  typedef const int *iptr;
  1019. +  iptr p = 0;
  1020. +  ++p;
  1021. +}
  1022. +{ /* AIX XL C 1.02.0.0 rejects this saying
  1023. +     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  1024. +  struct s { int j; const int *ap[3]; };
  1025. +  struct s *b; b->j = 5;
  1026. +}
  1027. +{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  1028. +  const int foo = 10;
  1029. +}'
  1030. +test -n "$silent" || echo "checking for lack of working const"
  1031. +cat > conftest.${ac_ext} <<EOF
  1032. +#include "confdefs.h"
  1033. +
  1034. +int main() { return 0; }
  1035. +int t() { $ac_prog; return 0; }
  1036. +EOF
  1037. +if eval $ac_compile; then
  1038. +  :
  1039. +else
  1040. +  rm -rf conftest*
  1041. +  
  1042. +{
  1043. +test -n "$verbose" && \
  1044. +echo "    defining" const to be empty
  1045. +echo "#define" const "" >> confdefs.h
  1046. +DEFS="$DEFS -Dconst="
  1047. +ac_sed_defs="${ac_sed_defs}\${ac_dA}const\${ac_dB}const\${ac_dC}\${ac_dD}
  1048. +\${ac_uA}const\${ac_uB}const\${ac_uC}\${ac_uD}
  1049. +\${ac_eA}const\${ac_eB}const\${ac_eC}\${ac_eD}
  1050. +"
  1051. +}
  1052. +
  1053. +fi
  1054. +rm -f conftest*
  1055. +
  1056. +
  1057. +
  1058. +# GNU libc predefines `program_invocation_name'.
  1059. +test -n "$silent" || echo "checking for program_invocation_name"
  1060. +cat > conftest.${ac_ext} <<EOF
  1061. +#include "confdefs.h"
  1062. +
  1063. +int main() { return 0; }
  1064. +int t() { main() { program_invocation_name = "hello"; }; return 0; }
  1065. +EOF
  1066. +if eval $ac_compile; then
  1067. +  rm -rf conftest*
  1068. +  
  1069. +{
  1070. +test -n "$verbose" && \
  1071. +echo "    defining HAVE_PROGRAM_INVOCATION_NAME"
  1072. +echo "#define" HAVE_PROGRAM_INVOCATION_NAME "1" >> confdefs.h
  1073. +DEFS="$DEFS -DHAVE_PROGRAM_INVOCATION_NAME=1"
  1074. +ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_PROGRAM_INVOCATION_NAME\${ac_dB}HAVE_PROGRAM_INVOCATION_NAME\${ac_dC}1\${ac_dD}
  1075. +\${ac_uA}HAVE_PROGRAM_INVOCATION_NAME\${ac_uB}HAVE_PROGRAM_INVOCATION_NAME\${ac_uC}1\${ac_uD}
  1076. +\${ac_eA}HAVE_PROGRAM_INVOCATION_NAME\${ac_eB}HAVE_PROGRAM_INVOCATION_NAME\${ac_eC}1\${ac_eD}
  1077. +"
  1078. +}
  1079. +
  1080. +
  1081. +
  1082. +fi
  1083. +rm -f conftest*
  1084. +
  1085. +
  1086. +# Some BSD systems do malloc/free's on the environment.
  1087. +# This test program is due to Mike Hibler <mike@cs.utah.edu>.
  1088. +test -n "$silent" || echo "checking for smart putenv"
  1089. +cat > conftest.${ac_ext} <<EOF
  1090. +#include "confdefs.h"
  1091. +
  1092. +int main() { return 0; }
  1093. +int t() { 
  1094. +#define VAR    "YOW_VAR"
  1095. +#define STRING1 "GabbaGabbaHey"
  1096. +#define STRING2 "Yow!!"        /* should be shorter than STRING1 */
  1097. +extern char *getenv (); /* in case char* and int don't mix gracefully */
  1098. +main ()
  1099. +{
  1100. +  char *str1, *rstr1, *str2, *rstr2;
  1101. +  str1 = getenv (VAR);
  1102. +  if (str1)
  1103. +    exit (1);
  1104. +  str1 = malloc (strlen (VAR) + 1 + strlen (STRING1) + 1);
  1105. +  if (str1 == 0)
  1106. +    exit (2);
  1107. +  strcpy (str1, VAR);
  1108. +  strcat (str1, "=");
  1109. +  strcat (str1, STRING1);
  1110. +  if (putenv (str1) < 0)
  1111. +    exit (3);
  1112. +  rstr1 = getenv (VAR);
  1113. +  if (rstr1 == 0)
  1114. +    exit (4);
  1115. +  rstr1 -= strlen (VAR) + 1;
  1116. +  if (strncmp (rstr1, VAR, strlen (VAR)))
  1117. +    exit (5);
  1118. +  str2 = malloc (strlen (VAR) + 1 + strlen (STRING2) + 1);
  1119. +  if (str2 == 0 || str1 == str2)
  1120. +    exit (6);
  1121. +  strcpy (str2, VAR);
  1122. +  strcat (str2, "=");
  1123. +  strcat (str2, STRING2);
  1124. +  if (putenv (str2) < 0)
  1125. +    exit (7);
  1126. +  rstr2 = getenv (VAR);
  1127. +  if (rstr2 == 0)
  1128. +    exit (8);
  1129. +  rstr2 -= strlen (VAR) + 1;
  1130. +#if 0
  1131. +  printf ("rstr1=0x%x, rstr2=0x%x\n", rstr1, rstr2);
  1132. +  /*
  1133. +   * If string from first call was reused for the second call,
  1134. +   * you had better not do a free on the first string!
  1135. +   */
  1136. +  if (rstr1 == rstr2)
  1137. +          printf ("#define\tSMART_PUTENV\n");
  1138. +  else
  1139. +          printf ("#undef\tSMART_PUTENV\n");
  1140. +#endif
  1141. +
  1142. +  exit (rstr1 == rstr2 ? 0 : 1);
  1143. +}
  1144. +; return 0; }
  1145. +EOF
  1146. +if eval $ac_compile; then
  1147. +  rm -rf conftest*
  1148. +  
  1149. +{
  1150. +test -n "$verbose" && \
  1151. +echo "    defining "
  1152. +echo "#define"  "1" >> confdefs.h
  1153. +DEFS="$DEFS -D=1"
  1154. +ac_sed_defs="${ac_sed_defs}\${ac_dA}\${ac_dB}\${ac_dC}1\${ac_dD}
  1155. +\${ac_uA}\${ac_uB}\${ac_uC}1\${ac_uD}
  1156. +\${ac_eA}\${ac_eB}\${ac_eC}1\${ac_eD}
  1157. +"
  1158. +}
  1159. + (SMART_PUTENV)
  1160. +
  1161. +
  1162. +fi
  1163. +rm -f conftest*
  1164. +
  1165. +
  1166. +
  1167. +
  1168. +for ac_prog in 'bison -y' byacc
  1169. +do
  1170. +if test -z "$YACC"; then
  1171. +  # Extract the first word of `$ac_prog', so it can be a program name with args.
  1172. +  set ac_dummy $ac_prog; ac_word=$2
  1173. +  test -n "$silent" || echo "checking for $ac_word"
  1174. +  IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1175. +  for ac_dir in $PATH; do
  1176. +    test -z "$ac_dir" && ac_dir=.
  1177. +    if test -f $ac_dir/$ac_word; then
  1178. +      YACC="$ac_prog"
  1179. +      break
  1180. +    fi
  1181. +  done
  1182. +  IFS="$ac_save_ifs"
  1183. +fi
  1184. +
  1185. +test -n "$YACC" && test -n "$verbose" && echo "    setting YACC to $YACC"
  1186. +
  1187. +test -n "$YACC" && break
  1188. +done
  1189. +test -n "$YACC" || YACC="yacc"
  1190. +
  1191. +if test -z "$LEX"; then
  1192. +  # Extract the first word of `flex', so it can be a program name with args.
  1193. +  set ac_dummy flex; ac_word=$2
  1194. +  test -n "$silent" || echo "checking for $ac_word"
  1195. +  IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1196. +  for ac_dir in $PATH; do
  1197. +    test -z "$ac_dir" && ac_dir=.
  1198. +    if test -f $ac_dir/$ac_word; then
  1199. +      LEX="flex"
  1200. +      break
  1201. +    fi
  1202. +  done
  1203. +  IFS="$ac_save_ifs"
  1204. +fi
  1205. +test -z "$LEX" && LEX="lex"
  1206. +test -n "$LEX" && test -n "$verbose" && echo "    setting LEX to $LEX"
  1207. +
  1208. +if test -z "$LEXLIB"
  1209. +then
  1210. +  case "$LEX" in
  1211. +  flex*) ac_save_LIBS="${LIBS}"
  1212. +LIBS="${LIBS} -lfl"
  1213. +ac_have_lib=""
  1214. +test -n "$silent" || echo "checking for -lfl"
  1215. +cat > conftest.${ac_ext} <<EOF
  1216. +#include "confdefs.h"
  1217. +
  1218. +int main() { return 0; }
  1219. +int t() { main();; return 0; }
  1220. +EOF
  1221. +if eval $ac_compile; then
  1222. +  rm -rf conftest*
  1223. +  ac_have_lib="1"
  1224. +
  1225. +fi
  1226. +rm -f conftest*
  1227. +LIBS="${ac_save_LIBS}"
  1228. +if test -n "${ac_have_lib}"; then
  1229. +   :; LEXLIB="-lfl"
  1230. +else
  1231. +   :; 
  1232. +fi
  1233. + ;;
  1234. +  *) LEXLIB="-ll" ;;
  1235. +  esac
  1236. +fi
  1237. +test -n "$verbose" && echo "    setting LEXLIB to $LEXLIB"
  1238. +
  1239. +test -n "$silent" || echo "checking for ln -s"
  1240. +rm -f conftestdata
  1241. +if ln -s X conftestdata 2>/dev/null
  1242. +then
  1243. +  rm -f conftestdata
  1244. +  LN_S="ln -s"
  1245. +else
  1246. +  LN_S=ln
  1247. +fi
  1248. +
  1249. +
  1250. +
  1251. +test -n "$silent" || echo "checking for return type of signal handlers"
  1252. +cat > conftest.${ac_ext} <<EOF
  1253. +#include "confdefs.h"
  1254. +#include <sys/types.h>
  1255. +#include <signal.h>
  1256. +#ifdef signal
  1257. +#undef signal
  1258. +#endif
  1259. +extern void (*signal ()) ();
  1260. +int main() { return 0; }
  1261. +int t() { int i;; return 0; }
  1262. +EOF
  1263. +if eval $ac_compile; then
  1264. +  rm -rf conftest*
  1265. +  
  1266. +{
  1267. +test -n "$verbose" && \
  1268. +echo "    defining" RETSIGTYPE to be "void"
  1269. +echo "#define" RETSIGTYPE "void" >> confdefs.h
  1270. +DEFS="$DEFS -DRETSIGTYPE=void"
  1271. +ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}void\${ac_dD}
  1272. +\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}void\${ac_uD}
  1273. +\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}void\${ac_eD}
  1274. +"
  1275. +}
  1276. +
  1277. +
  1278. +else
  1279. +  rm -rf conftest*
  1280. +  
  1281. +{
  1282. +test -n "$verbose" && \
  1283. +echo "    defining" RETSIGTYPE to be "int"
  1284. +echo "#define" RETSIGTYPE "int" >> confdefs.h
  1285. +DEFS="$DEFS -DRETSIGTYPE=int"
  1286. +ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}int\${ac_dD}
  1287. +\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}int\${ac_uD}
  1288. +\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}int\${ac_eD}
  1289. +"
  1290. +}
  1291. +
  1292. +fi
  1293. +rm -f conftest*
  1294. +
  1295. +
  1296. +
  1297. +test -n "$silent" || echo "checking for unsigned characters"
  1298. +cat > conftest.${ac_ext} <<EOF
  1299. +#include "confdefs.h"
  1300. +/* volatile prevents gcc2 from optimizing the test away on sparcs.  */
  1301. +#if !__STDC__
  1302. +#define volatile
  1303. +#endif
  1304. +main() {
  1305. +#ifdef __CHAR_UNSIGNED__
  1306. +  exit(1); /* No need to redefine it.  */
  1307. +#else
  1308. +  volatile char c = 255; exit(c < 0);
  1309. +#endif
  1310. +}
  1311. +EOF
  1312. +eval $ac_compile
  1313. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1314. +  
  1315. +{
  1316. +test -n "$verbose" && \
  1317. +echo "    defining __CHAR_UNSIGNED__"
  1318. +echo "#define" __CHAR_UNSIGNED__ "1" >> confdefs.h
  1319. +DEFS="$DEFS -D__CHAR_UNSIGNED__=1"
  1320. +ac_sed_defs="${ac_sed_defs}\${ac_dA}__CHAR_UNSIGNED__\${ac_dB}__CHAR_UNSIGNED__\${ac_dC}1\${ac_dD}
  1321. +\${ac_uA}__CHAR_UNSIGNED__\${ac_uB}__CHAR_UNSIGNED__\${ac_uC}1\${ac_uD}
  1322. +\${ac_eA}__CHAR_UNSIGNED__\${ac_eB}__CHAR_UNSIGNED__\${ac_eC}1\${ac_eD}
  1323. +"
  1324. +}
  1325. +
  1326. +
  1327. +fi
  1328. +rm -fr conftest*
  1329. +
  1330. +
  1331. +test -n "$silent" || echo "checking for 64-bit long ints"
  1332. +cat > conftest.${ac_ext} <<EOF
  1333. +#include "confdefs.h"
  1334. +main() { exit(sizeof(long int) != 8); }
  1335. +EOF
  1336. +eval $ac_compile
  1337. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1338. +  
  1339. +{
  1340. +test -n "$verbose" && \
  1341. +echo "    defining LONG_64_BITS"
  1342. +echo "#define" LONG_64_BITS "1" >> confdefs.h
  1343. +DEFS="$DEFS -DLONG_64_BITS=1"
  1344. +ac_sed_defs="${ac_sed_defs}\${ac_dA}LONG_64_BITS\${ac_dB}LONG_64_BITS\${ac_dC}1\${ac_dD}
  1345. +\${ac_uA}LONG_64_BITS\${ac_uB}LONG_64_BITS\${ac_uC}1\${ac_uD}
  1346. +\${ac_eA}LONG_64_BITS\${ac_eB}LONG_64_BITS\${ac_eC}1\${ac_eD}
  1347. +"
  1348. +}
  1349. +
  1350. +
  1351. +fi
  1352. +rm -fr conftest*
  1353. +
  1354. +test -n "$silent" || echo "checking byte ordering"
  1355. +cat > conftest.${ac_ext} <<EOF
  1356. +#include "confdefs.h"
  1357. +main () {
  1358. +  /* Are we little or big endian?  From Harbison&Steele.  */
  1359. +  union
  1360. +  {
  1361. +    long l;
  1362. +    char c[sizeof (long)];
  1363. +  } u;
  1364. +  u.l = 1;
  1365. +  exit (u.c[sizeof (long) - 1] == 1);
  1366. +}
  1367. +EOF
  1368. +eval $ac_compile
  1369. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1370. +  :
  1371. +else
  1372. +  
  1373. +{
  1374. +test -n "$verbose" && \
  1375. +echo "    defining WORDS_BIGENDIAN"
  1376. +echo "#define" WORDS_BIGENDIAN "1" >> confdefs.h
  1377. +DEFS="$DEFS -DWORDS_BIGENDIAN=1"
  1378. +ac_sed_defs="${ac_sed_defs}\${ac_dA}WORDS_BIGENDIAN\${ac_dB}WORDS_BIGENDIAN\${ac_dC}1\${ac_dD}
  1379. +\${ac_uA}WORDS_BIGENDIAN\${ac_uB}WORDS_BIGENDIAN\${ac_uC}1\${ac_uD}
  1380. +\${ac_eA}WORDS_BIGENDIAN\${ac_eB}WORDS_BIGENDIAN\${ac_eC}1\${ac_eD}
  1381. +"
  1382. +}
  1383. +
  1384. +fi
  1385. +rm -fr conftest*
  1386. +
  1387. +
  1388. +test -n "$silent" || echo "checking for yytext declaration"
  1389. +# POSIX says lex can declare yytext either as a pointer or an array; the
  1390. +# default is implementation-dependent. Figure out which it is, since
  1391. +# not all implementations provide the %pointer and %array declarations.
  1392. +#
  1393. +# The minimal lex program is just a single line: %%.  But some broken lexes
  1394. +# (Solaris, I think it was) want two %% lines, so accommodate them.
  1395. +  echo '%%
  1396. +%%' | ${LEX}
  1397. +if test -f lex.yy.c; then
  1398. +  LEX_OUTPUT_ROOT=lex.yy
  1399. +elif test -f lexyy.c; then
  1400. +  LEX_OUTPUT_ROOT=lexyy
  1401. +else
  1402. +  # Don't know what to do here.
  1403. +  echo "configure: cannot find output from $LEX" >&2; exit 1
  1404. +  LEX_OUTPUT_ROOT=
  1405. +fi
  1406. +if test -n "$LEX_OUTPUT_ROOT"; then
  1407. +  echo 'extern char *yytext; main () { exit (0); }' >>$LEX_OUTPUT_ROOT.c
  1408. +  ac_save_LIBS="$LIBS"
  1409. +  LIBS="$LIBS $LEXLIB"
  1410. +  cat > conftest.${ac_ext} <<EOF
  1411. +#include "confdefs.h"
  1412. +`cat $LEX_OUTPUT_ROOT.c`
  1413. +EOF
  1414. +eval $ac_compile
  1415. +if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1416. +  
  1417. +{
  1418. +test -n "$verbose" && \
  1419. +echo "    defining YYTEXT_POINTER"
  1420. +echo "#define" YYTEXT_POINTER "1" >> confdefs.h
  1421. +DEFS="$DEFS -DYYTEXT_POINTER=1"
  1422. +ac_sed_defs="${ac_sed_defs}\${ac_dA}YYTEXT_POINTER\${ac_dB}YYTEXT_POINTER\${ac_dC}1\${ac_dD}
  1423. +\${ac_uA}YYTEXT_POINTER\${ac_uB}YYTEXT_POINTER\${ac_uC}1\${ac_uD}
  1424. +\${ac_eA}YYTEXT_POINTER\${ac_eB}YYTEXT_POINTER\${ac_eC}1\${ac_eD}
  1425. +"
  1426. +}
  1427. +
  1428. +
  1429. +fi
  1430. +rm -fr conftest*
  1431. +  LIBS="$ac_save_LIBS"
  1432. +  rm -f "${LEX_OUTPUT_ROOT}.c"
  1433. +fi
  1434. +
  1435. +
  1436. +echo checking for window system libraries
  1437. +cat > conftest.${ac_ext} <<EOF
  1438. +#include "confdefs.h"
  1439. +#include "$srcdir/lib/c-auto.h.in"
  1440. +#ifndef SUNWIN
  1441. +#include <nonexistxyz.kkk>
  1442. +#endif
  1443. +
  1444. +EOF
  1445. +# Some shells (Coherent) do redirections in the wrong order, so need
  1446. +# the parens.
  1447. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1448. +if test -z "$ac_err"; then
  1449. +  rm -rf conftest*
  1450. +  SUNWIN=t
  1451. +
  1452. +
  1453. +fi
  1454. +rm -f conftest*
  1455. +cat > conftest.${ac_ext} <<EOF
  1456. +#include "confdefs.h"
  1457. +#include "$srcdir/lib/c-auto.h.in"
  1458. +#ifndef XVIEWWIN
  1459. +#include <nonexistxyz.kkk>
  1460. +#endif
  1461. +
  1462. +EOF
  1463. +# Some shells (Coherent) do redirections in the wrong order, so need
  1464. +# the parens.
  1465. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1466. +if test -z "$ac_err"; then
  1467. +  rm -rf conftest*
  1468. +  XVIEWWIN=t
  1469. +
  1470. +
  1471. +fi
  1472. +rm -f conftest*
  1473. +cat > conftest.${ac_ext} <<EOF
  1474. +#include "confdefs.h"
  1475. +#include "$srcdir/lib/c-auto.h.in"
  1476. +#ifndef X11WIN
  1477. +#include <nonexistxyz.kkk>
  1478. +#endif
  1479. +
  1480. +EOF
  1481. +# Some shells (Coherent) do redirections in the wrong order, so need
  1482. +# the parens.
  1483. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1484. +if test -z "$ac_err"; then
  1485. +  rm -rf conftest*
  1486. +  X11WIN=t
  1487. +
  1488. +
  1489. +fi
  1490. +rm -f conftest*
  1491. +cat > conftest.${ac_ext} <<EOF
  1492. +#include "confdefs.h"
  1493. +#include "$srcdir/lib/c-auto.h.in"
  1494. +#ifndef X10WIN
  1495. +#include <nonexistxyz.kkk>
  1496. +#endif
  1497. +
  1498. +EOF
  1499. +# Some shells (Coherent) do redirections in the wrong order, so need
  1500. +# the parens.
  1501. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1502. +if test -z "$ac_err"; then
  1503. +  rm -rf conftest*
  1504. +  X10WIN=t
  1505. +
  1506. +
  1507. +fi
  1508. +rm -f conftest*
  1509. +if test -n "$XVIEWWIN"; then
  1510. +  wlibs="-lxview -lolgx -lX11 $wlibs"
  1511. +  (cd $srcdir/mf/MFwindow; rm -f sun.c; $LN_S sun-xview.c sun.c)
  1512. +fi
  1513. +if test -n "$X11WIN"; then
  1514. +  # If we find X, set shell vars x_includes and x_libraries to the paths.
  1515. +no_x=true
  1516. +if test "x$with_x" != xno; then
  1517. +test -n "$silent" || echo "checking for X include and library files with xmkmf"
  1518. +rm -fr conftestdir
  1519. +if mkdir conftestdir; then
  1520. +  cd conftestdir
  1521. +  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
  1522. +  cat > Imakefile <<'EOF'
  1523. +acfindx:
  1524. +    @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
  1525. +EOF
  1526. +  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
  1527. +    no_x=
  1528. +    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
  1529. +    eval `make acfindx 2>/dev/null | grep -v make`
  1530. +    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
  1531. +    if test ! -f $ac_im_usrlibdir/libX11.a && test -f $ac_im_libdir/libX11.a
  1532. +    then
  1533. +      ac_im_usrlibdir=$ac_im_libdir
  1534. +    fi
  1535. +    case "$ac_im_incroot" in
  1536. +    /usr/include) ;;
  1537. +    *) test -z "$x_includes" && x_includes="$ac_im_incroot" ;;
  1538. +    esac
  1539. +    case "$ac_im_usrlibdir" in
  1540. +    /usr/lib | /lib) ;;
  1541. +    *) test -z "$x_libraries" && x_libraries="$ac_im_usrlibdir" ;;
  1542. +    esac
  1543. +  fi
  1544. +  cd ..
  1545. +  rm -fr conftestdir
  1546. +fi
  1547. +
  1548. +if test -z "$ac_im_usrlibdir"; then
  1549. +test -n "$silent" || echo "checking for X include and library files directly"
  1550. +if test ".$x_direct_test_library" = . ; then
  1551. +   x_direct_test_library='Xt'
  1552. +fi
  1553. +if test ".$x_direct_test_include" = . ; then
  1554. +   x_direct_test_include='X11/Intrinsic.h'
  1555. +fi
  1556. +cat > conftest.${ac_ext} <<EOF
  1557. +#include "confdefs.h"
  1558. +#include <$x_direct_test_include>
  1559. +EOF
  1560. +# Some shells (Coherent) do redirections in the wrong order, so need
  1561. +# the parens.
  1562. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1563. +if test -z "$ac_err"; then
  1564. +  rm -rf conftest*
  1565. +  no_x=
  1566. +
  1567. +else
  1568. +  rm -rf conftest*
  1569. +  for ac_dir in               \
  1570. +    /usr/X11R6/include        \
  1571. +    /usr/X11R5/include        \
  1572. +    /usr/X11R4/include        \
  1573. +                              \
  1574. +    /usr/include/X11R6        \
  1575. +    /usr/include/X11R5        \
  1576. +    /usr/include/X11R4        \
  1577. +                              \
  1578. +    /usr/local/X11R6/include  \
  1579. +    /usr/local/X11R5/include  \
  1580. +    /usr/local/X11R4/include  \
  1581. +                              \
  1582. +    /usr/local/include/X11R6  \
  1583. +    /usr/local/include/X11R5  \
  1584. +    /usr/local/include/X11R4  \
  1585. +                              \
  1586. +    /usr/X11/include          \
  1587. +    /usr/include/X11          \
  1588. +    /usr/local/X11/include    \
  1589. +    /usr/local/include/X11    \
  1590. +                              \
  1591. +    /usr/X386/include         \
  1592. +    /usr/x386/include         \
  1593. +    /usr/XFree86/include/X11  \
  1594. +                              \
  1595. +    /usr/include              \
  1596. +    /usr/local/include        \
  1597. +    /usr/unsupported/include  \
  1598. +    /usr/athena/include       \
  1599. +    /usr/local/x11r5/include  \
  1600. +    /usr/lpp/Xamples/include  \
  1601. +                              \
  1602. +    /usr/openwin/include      \
  1603. +    /usr/openwin/share/include \
  1604. +    ; \
  1605. +  do
  1606. +    if test -r "$ac_dir/$x_direct_test_include"; then
  1607. +      test -z "$x_includes" && x_includes=$ac_dir
  1608. +      no_x=
  1609. +      break
  1610. +    fi
  1611. +  done
  1612. +fi
  1613. +rm -f conftest*
  1614. +
  1615. +# Check for the libraries.  First see if replacing the `include' by
  1616. +# `lib' works.
  1617. +ac_save_LIBS="${LIBS}"
  1618. +LIBS="${LIBS} -l"$x_direct_test_library""
  1619. +ac_have_lib=""
  1620. +test -n "$silent" || echo "checking for -l"$x_direct_test_library""
  1621. +cat > conftest.${ac_ext} <<EOF
  1622. +#include "confdefs.h"
  1623. +
  1624. +int main() { return 0; }
  1625. +int t() { main();; return 0; }
  1626. +EOF
  1627. +if eval $ac_compile; then
  1628. +  rm -rf conftest*
  1629. +  ac_have_lib="1"
  1630. +
  1631. +fi
  1632. +rm -f conftest*
  1633. +LIBS="${ac_save_LIBS}"
  1634. +if test -n "${ac_have_lib}"; then
  1635. +   :; no_x=
  1636. +else
  1637. +   :; for ac_dir in `echo "$x_includes" | sed s/include/lib/` \
  1638. +    /usr/X11R6/lib        \
  1639. +    /usr/X11R5/lib        \
  1640. +    /usr/X11R4/lib        \
  1641. +                          \
  1642. +    /usr/lib/X11R6        \
  1643. +    /usr/lib/X11R5        \
  1644. +    /usr/lib/X11R4        \
  1645. +                          \
  1646. +    /usr/local/X11R6/lib  \
  1647. +    /usr/local/X11R5/lib  \
  1648. +    /usr/local/X11R4/lib  \
  1649. +                          \
  1650. +    /usr/local/lib/X11R6  \
  1651. +    /usr/local/lib/X11R5  \
  1652. +    /usr/local/lib/X11R4  \
  1653. +                          \
  1654. +    /usr/X11/lib          \
  1655. +    /usr/lib/X11          \
  1656. +    /usr/local/X11/lib    \
  1657. +    /usr/local/lib/X11    \
  1658. +                          \
  1659. +    /usr/X386/lib         \
  1660. +    /usr/x386/lib         \
  1661. +    /usr/XFree86/lib/X11  \
  1662. +                          \
  1663. +    /usr/lib              \
  1664. +    /usr/local/lib        \
  1665. +    /usr/unsupported/lib  \
  1666. +    /usr/athena/lib       \
  1667. +    /usr/local/x11r5/lib  \
  1668. +    /usr/lpp/Xamples/lib  \
  1669. +                          \
  1670. +    /usr/openwin/lib      \
  1671. +    /usr/openwin/share/lib \
  1672. +    ; \
  1673. +do
  1674. +  for ac_extension in a so sl; do
  1675. +    if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
  1676. +      test -z "$x_libraries" && x_libraries=$ac_dir
  1677. +      no_x=
  1678. +      break 2
  1679. +    fi
  1680. +  done
  1681. +done
  1682. +fi
  1683. +
  1684. +fi
  1685. +test -n "$x_includes" && test -n "$verbose" && echo "    X11 headers are in $x_includes"
  1686. +test -n "$x_libraries" && test -n "$verbose" && echo "    X11 libraries are in $x_libraries"
  1687. +fi
  1688. +
  1689. +  
  1690. +test -n "$silent" || echo "checking for additional X libraries and flags"
  1691. +if test -n "$x_includes"; then
  1692. +  X_CFLAGS="$X_CFLAGS -I$x_includes"
  1693. +elif test -n "$no_x"; then 
  1694. +  # Not all programs may use this symbol, but it won't hurt to define it.
  1695. +  X_CFLAGS="$X_CFLAGS -DX_DISPLAY_MISSING"
  1696. +fi
  1697. +
  1698. +# It would be nice to have a more robust check for the -R ld option than
  1699. +# just checking for Solaris.
  1700. +# It would also be nice to do this for all -L options, not just this one.
  1701. +if test -n "$x_libraries"; then
  1702. +  X_LIBS="$X_LIBS -L$x_libraries"
  1703. +  if test "`(uname) 2>/dev/null`" = SunOS \
  1704. +     && uname -r | grep '^5' >/dev/null; then
  1705. +    X_LIBS="$X_LIBS -R$x_libraries"
  1706. +  fi
  1707. +fi
  1708. +
  1709. +# Check for libraries that R6 introduced. Xt/Xaw programs need these, at
  1710. +# least xdvi(k) on Ultrix.
  1711. +save_ldflags=$LDFLAGS
  1712. +save_libs=$LIBS
  1713. +LDFLAGS="$LDFLAGS -L$x_libraries"
  1714. +ac_save_LIBS="${LIBS}"
  1715. +LIBS="${LIBS} -lICE"
  1716. +ac_have_lib=""
  1717. +test -n "$silent" || echo "checking for -lICE"
  1718. +cat > conftest.${ac_ext} <<EOF
  1719. +#include "confdefs.h"
  1720. +
  1721. +int main() { return 0; }
  1722. +int t() { main();; return 0; }
  1723. +EOF
  1724. +if eval $ac_compile; then
  1725. +  rm -rf conftest*
  1726. +  ac_have_lib="1"
  1727. +
  1728. +fi
  1729. +rm -f conftest*
  1730. +LIBS="${ac_save_LIBS}"
  1731. +if test -n "${ac_have_lib}"; then
  1732. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -lICE"
  1733. +else
  1734. +   :; 
  1735. +fi
  1736. +
  1737. +# SM needs ICE to (dynamically) link under SunOS 4.x.
  1738. +# (From interran@uluru.Stanford.EDU.)
  1739. +LIBS="$LIBS -lICE"
  1740. +ac_save_LIBS="${LIBS}"
  1741. +LIBS="${LIBS} -lSM"
  1742. +ac_have_lib=""
  1743. +test -n "$silent" || echo "checking for -lSM"
  1744. +cat > conftest.${ac_ext} <<EOF
  1745. +#include "confdefs.h"
  1746. +
  1747. +int main() { return 0; }
  1748. +int t() { main();; return 0; }
  1749. +EOF
  1750. +if eval $ac_compile; then
  1751. +  rm -rf conftest*
  1752. +  ac_have_lib="1"
  1753. +
  1754. +fi
  1755. +rm -f conftest*
  1756. +LIBS="${ac_save_LIBS}"
  1757. +if test -n "${ac_have_lib}"; then
  1758. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -lSM"
  1759. +else
  1760. +   :; 
  1761. +fi
  1762. +
  1763. +LDFLAGS=$save_ldflags
  1764. +LIBS=$save_libs
  1765. +
  1766. +# Check for system-dependent libraries X programs must link with.
  1767. +if test -n "$ISC"; then
  1768. +  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
  1769. +else
  1770. +  # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
  1771. +  # libraries were built with DECnet support.  And karl@cs.umb.edu's Alpha
  1772. +  # needs dnet_stub (dnet doesn't exist).
  1773. +  ac_save_LIBS="${LIBS}"
  1774. +LIBS="${LIBS} -ldnet"
  1775. +ac_have_lib=""
  1776. +test -n "$silent" || echo "checking for -ldnet"
  1777. +cat > conftest.${ac_ext} <<EOF
  1778. +#include "confdefs.h"
  1779. +
  1780. +int main() { return 0; }
  1781. +int t() { main();; return 0; }
  1782. +EOF
  1783. +if eval $ac_compile; then
  1784. +  rm -rf conftest*
  1785. +  ac_have_lib="1"
  1786. +
  1787. +fi
  1788. +rm -f conftest*
  1789. +LIBS="${ac_save_LIBS}"
  1790. +if test -n "${ac_have_lib}"; then
  1791. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
  1792. +     ac_have_dnet=t
  1793. +else
  1794. +   :; 
  1795. +fi
  1796. +
  1797. +  if test -z "$ac_have_dnet"; then
  1798. +    ac_save_LIBS="${LIBS}"
  1799. +LIBS="${LIBS} -ldnet_stub"
  1800. +ac_have_lib=""
  1801. +test -n "$silent" || echo "checking for -ldnet_stub"
  1802. +cat > conftest.${ac_ext} <<EOF
  1803. +#include "confdefs.h"
  1804. +
  1805. +int main() { return 0; }
  1806. +int t() { main();; return 0; }
  1807. +EOF
  1808. +if eval $ac_compile; then
  1809. +  rm -rf conftest*
  1810. +  ac_have_lib="1"
  1811. +
  1812. +fi
  1813. +rm -f conftest*
  1814. +LIBS="${ac_save_LIBS}"
  1815. +if test -n "${ac_have_lib}"; then
  1816. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
  1817. +else
  1818. +   :; 
  1819. +fi
  1820. +
  1821. +  fi
  1822. +  #
  1823. +  # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT.
  1824. +  # Not sure which flavor of 386 Unix this is, but it seems harmless to
  1825. +  # check for it.
  1826. +  ac_save_LIBS="${LIBS}"
  1827. +LIBS="${LIBS} -lnsl"
  1828. +ac_have_lib=""
  1829. +test -n "$silent" || echo "checking for -lnsl"
  1830. +cat > conftest.${ac_ext} <<EOF
  1831. +#include "confdefs.h"
  1832. +
  1833. +int main() { return 0; }
  1834. +int t() { main();; return 0; }
  1835. +EOF
  1836. +if eval $ac_compile; then
  1837. +  rm -rf conftest*
  1838. +  ac_have_lib="1"
  1839. +
  1840. +fi
  1841. +rm -f conftest*
  1842. +LIBS="${ac_save_LIBS}"
  1843. +if test -n "${ac_have_lib}"; then
  1844. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
  1845. +else
  1846. +   :; 
  1847. +fi
  1848. +
  1849. +  #
  1850. +  # lieder@skyler.mavd.honeywell.com says without -lsocket,
  1851. +  # socket/setsockopt and other routines are undefined under SCO ODT 2.0.
  1852. +  # But -lsocket is broken on IRIX, according to simon@lia.di.epfl.ch.
  1853. +  if test "`(uname) 2>/dev/null`" != IRIX; then
  1854. +    ac_save_LIBS="${LIBS}"
  1855. +LIBS="${LIBS} -lsocket"
  1856. +ac_have_lib=""
  1857. +test -n "$silent" || echo "checking for -lsocket"
  1858. +cat > conftest.${ac_ext} <<EOF
  1859. +#include "confdefs.h"
  1860. +
  1861. +int main() { return 0; }
  1862. +int t() { main();; return 0; }
  1863. +EOF
  1864. +if eval $ac_compile; then
  1865. +  rm -rf conftest*
  1866. +  ac_have_lib="1"
  1867. +
  1868. +fi
  1869. +rm -f conftest*
  1870. +LIBS="${ac_save_LIBS}"
  1871. +if test -n "${ac_have_lib}"; then
  1872. +   :; X_EXTRA_LIBS="$X_EXTRA_LIBS -lsocket"
  1873. +else
  1874. +   :; 
  1875. +fi
  1876. +
  1877. +  fi
  1878. +fi
  1879. +#
  1880. +test -n "$verbose" && echo "    X compiler flags: $X_CFLAGS"
  1881. +test -n "$verbose" && echo "    X library flags: $X_LIBS"
  1882. +test -n "$verbose" && echo "    extra X libraries: $X_EXTRA_LIBS"
  1883. +
  1884. +  wlibs="-lXt $X_EXTRA_LIBS -lX11 $wlibs"
  1885. +  (cd $srcdir/mf/MFwindow; rm -f x11.c; $LN_S x11-Xt.c x11.c)
  1886. +fi
  1887. +if test -n "$X10WIN"; then
  1888. +  wlibs="-lX $wlibs"
  1889. +fi
  1890. +if test -n "$SUNWIN"; then
  1891. +  wlibs="-lsuntool -lsunwindow -lpixrect $wlibs"
  1892. +  (cd $srcdir/mf/MFwindow; rm -f sun.c; $LN_S sun-sunview.c sun.c)
  1893. +fi
  1894. +
  1895. +
  1896. +echo checking for small TeX/MF/BibTeX
  1897. +# Do TeX first.
  1898. +# If `small' version is not wanted, do nothing -- make will copy the
  1899. +# default change file.
  1900. +cat > conftest.${ac_ext} <<EOF
  1901. +#include "confdefs.h"
  1902. +#include "$srcdir/lib/c-auto.h.in"
  1903. +#ifndef SMALLTeX
  1904. +#include <nonexistxyz.kkk>
  1905. +#endif
  1906. +
  1907. +EOF
  1908. +# Some shells (Coherent) do redirections in the wrong order, so need
  1909. +# the parens.
  1910. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1911. +if test -z "$ac_err"; then
  1912. +  rm -rf conftest*
  1913. +  SMALLTeX=t
  1914. +
  1915. +
  1916. +fi
  1917. +rm -f conftest*
  1918. +if test -n "$SMALLTeX"; then
  1919. +  echo "(small TeX, creating tex/ctex.ch)"
  1920. +  (cd $srcdir/tex && rm -f ctex.ch && sed -f small.sed <tex.ch >ctex.ch)
  1921. +  
  1922. +{
  1923. +test -n "$verbose" && \
  1924. +echo "    defining" GLUERATIO_TYPE to be "float"
  1925. +echo "#define" GLUERATIO_TYPE "float" >> confdefs.h
  1926. +DEFS="$DEFS -DGLUERATIO_TYPE=float"
  1927. +ac_sed_defs="${ac_sed_defs}\${ac_dA}GLUERATIO_TYPE\${ac_dB}GLUERATIO_TYPE\${ac_dC}float\${ac_dD}
  1928. +\${ac_uA}GLUERATIO_TYPE\${ac_uB}GLUERATIO_TYPE\${ac_uC}float\${ac_uD}
  1929. +\${ac_eA}GLUERATIO_TYPE\${ac_eB}GLUERATIO_TYPE\${ac_eC}float\${ac_eD}
  1930. +"
  1931. +}
  1932. +
  1933. +fi
  1934. +
  1935. +# Metafont next.
  1936. +cat > conftest.${ac_ext} <<EOF
  1937. +#include "confdefs.h"
  1938. +#include "$srcdir/lib/c-auto.h.in"
  1939. +#ifndef SMALLMF
  1940. +#include <nonexistxyz.kkk>
  1941. +#endif
  1942. +
  1943. +EOF
  1944. +# Some shells (Coherent) do redirections in the wrong order, so need
  1945. +# the parens.
  1946. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1947. +if test -z "$ac_err"; then
  1948. +  rm -rf conftest*
  1949. +  SMALLMF=t
  1950. +
  1951. +
  1952. +fi
  1953. +rm -f conftest*
  1954. +if test -n "$SMALLMF"; then
  1955. +  echo "(small Metafont, creating mf/cmf.ch)"
  1956. +  (cd $srcdir/mf && rm -f cmf.ch && sed -f small.sed <mf.ch >cmf.ch)
  1957. +fi
  1958. +
  1959. +# And finally BibTeX.
  1960. +cat > conftest.${ac_ext} <<EOF
  1961. +#include "confdefs.h"
  1962. +#include "$srcdir/lib/c-auto.h.in"
  1963. +#ifndef SMALLBibTeX
  1964. +#include <nonexistxyz.kkk>
  1965. +#endif
  1966. +
  1967. +EOF
  1968. +# Some shells (Coherent) do redirections in the wrong order, so need
  1969. +# the parens.
  1970. +ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"`
  1971. +if test -z "$ac_err"; then
  1972. +  rm -rf conftest*
  1973. +  SMALLBibTeX=t
  1974. +
  1975. +
  1976. +fi
  1977. +rm -f conftest*
  1978. +if test -n "$SMALLBibTeX"; then
  1979. +  echo "(small BibTeX, creating bibtex/cbibtex.ch)"
  1980. +  (cd $srcdir/bibtex \
  1981. +   && rm -f cbibtex.ch && sed -f small.sed <bibtex.ch >cbibtex.ch)
  1982. +fi
  1983. +
  1984. +
  1985. +# The preferred way to propogate these variables is regular @ substitutions.
  1986. +if test -n "$prefix"; then
  1987. +  ac_prsub="s%^prefix\\([     ]*\\)=\\([     ]*\\).*$%prefix\\1=\\2$prefix%"
  1988. +else
  1989. +  prefix=/usr/local
  1990. +fi
  1991. +if test -n "$exec_prefix"; then
  1992. +  ac_prsub="$ac_prsub
  1993. +s%^exec_prefix\\([     ]*\\)=\\([     ]*\\).*$%exec_prefix\\1=\\2$exec_prefix%"
  1994. +else
  1995. +  exec_prefix='${prefix}' # Let make expand it.
  1996. +fi
  1997. +
  1998. +# Any assignment to VPATH causes Sun make to only execute
  1999. +# the first set of double-colon rules, so remove it if not needed.
  2000. +# If there is a colon in the path, we need to keep it.
  2001. +if test "x$srcdir" = x.; then
  2002. +  ac_vpsub='/^[     ]*VPATH[     ]*=[^:]*$/d'
  2003. +fi
  2004. +
  2005. +# Quote sed substitution magic chars in DEFS.
  2006. +cat >conftest.def <<EOF
  2007. +$DEFS
  2008. +EOF
  2009. +ac_escape_ampersand_and_backslash='s%[&\\]%\\&%g'
  2010. +DEFS=`sed "$ac_escape_ampersand_and_backslash" <conftest.def`
  2011. +rm -f conftest.def
  2012. +# Substitute for predefined variables.
  2013. +
  2014. +trap 'rm -f config.status; exit 1' 1 2 15
  2015. +echo creating config.status
  2016. +rm -f config.status
  2017. +cat > config.status <<EOF
  2018. +#!/bin/sh
  2019. +# Generated automatically by configure.
  2020. +# Run this file to recreate the current configuration.
  2021. +# This directory was configured as follows,
  2022. +# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  2023. +#
  2024. +# $0 $configure_args
  2025. +
  2026. +ac_cs_usage="Usage: config.status [--recheck] [--version] [--help]"
  2027. +for ac_option
  2028. +do
  2029. +  case "\$ac_option" in
  2030. +  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  2031. +    echo running \${CONFIG_SHELL-/bin/sh} $0 $configure_args --no-create
  2032. +    exec \${CONFIG_SHELL-/bin/sh} $0 $configure_args --no-create ;;
  2033. +  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  2034. +    echo "config.status generated by autoconf version 1.11"
  2035. +    exit 0 ;;
  2036. +  -help | --help | --hel | --he | --h)
  2037. +    echo "\$ac_cs_usage"; exit 0 ;;
  2038. +  *) echo "\$ac_cs_usage"; exit 1 ;;
  2039. +  esac
  2040. +done
  2041. +
  2042. +trap 'rm -fr Makefile bibtex/Makefile dviutil/Makefile fontutil/Makefile \
  2043. +lib/Makefile man/Makefile mf/Makefile mf/MFwindow/Makefile \
  2044. +tex/Makefile web/Makefile web2c/Makefile lib/c-auto.h conftest*; exit 1' 1 2 15
  2045. +CC='$CC'
  2046. +CPP='$CPP'
  2047. +INSTALL='$INSTALL'
  2048. +INSTALL_PROGRAM='$INSTALL_PROGRAM'
  2049. +INSTALL_DATA='$INSTALL_DATA'
  2050. +RANLIB='$RANLIB'
  2051. +YACC='$YACC'
  2052. +LEX='$LEX'
  2053. +LEXLIB='$LEXLIB'
  2054. +LN_S='$LN_S'
  2055. +LEX_OUTPUT_ROOT='$LEX_OUTPUT_ROOT'
  2056. +X_CFLAGS='$X_CFLAGS'
  2057. +X_LIBS='$X_LIBS'
  2058. +X_EXTRA_LIBS='$X_EXTRA_LIBS'
  2059. +wlibs='$wlibs'
  2060. +LIBS='$LIBS'
  2061. +srcdir='$srcdir'
  2062. +top_srcdir='$top_srcdir'
  2063. +prefix='$prefix'
  2064. +exec_prefix='$exec_prefix'
  2065. +ac_prsub='$ac_prsub'
  2066. +ac_vpsub='$ac_vpsub'
  2067. +extrasub='$extrasub'
  2068. +EOF
  2069. +cat >> config.status <<\EOF
  2070. +
  2071. +ac_given_srcdir=$srcdir
  2072. +
  2073. +CONFIG_FILES=${CONFIG_FILES-"Makefile bibtex/Makefile dviutil/Makefile fontutil/Makefile \
  2074. +lib/Makefile man/Makefile mf/Makefile mf/MFwindow/Makefile \
  2075. +tex/Makefile web/Makefile web2c/Makefile"}
  2076. +for ac_file in .. ${CONFIG_FILES}; do if test "x$ac_file" != x..; then
  2077. +  # Remove last slash and all that follows it.  Not all systems have dirname.
  2078. +  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  2079. +  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  2080. +    # The file is in a subdirectory.
  2081. +    test ! -d "$ac_dir" && mkdir "$ac_dir"
  2082. +    ac_dir_suffix="/$ac_dir"
  2083. +  else
  2084. +    ac_dir_suffix=
  2085. +  fi
  2086. +
  2087. +  # A "../" for each directory in $ac_dir_suffix.
  2088. +  ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  2089. +  case "$ac_given_srcdir" in
  2090. +  .)  srcdir=.
  2091. +      if test -z "$ac_dir_suffix"; then top_srcdir=.
  2092. +      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  2093. +  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  2094. +  *) # Relative path.
  2095. +    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  2096. +    top_srcdir="$ac_dots$ac_given_srcdir" ;;
  2097. +  esac
  2098. +
  2099. +  echo creating "$ac_file"
  2100. +  rm -f "$ac_file"
  2101. +  comment_str="Generated automatically from `echo $ac_file|sed 's|.*/||'`.in by configure."
  2102. +  case "$ac_file" in
  2103. +    *.c | *.h | *.C | *.cc | *.m )  echo "/* $comment_str */" > "$ac_file" ;;
  2104. +    * )          echo "# $comment_str"     > "$ac_file" ;;
  2105. +  esac
  2106. +  # Replace lines of the form ac_include foo with the contents of foo:
  2107. +  # first, from the ac_include lines construct a list of sed
  2108. +  # commands to remove them, and include the files; then run sed.
  2109. +  # Have to use sed because old (Ultrix, SunOS) awk does not support
  2110. +  # getline or system. (Anyway, configure scripts aren't supposed to use awk.)
  2111. +  # Use \@...@<cmd> form of sed address because the filename may contain /.
  2112. +  # Can't use only one -e and commands {dr foo} because foo has to be last.
  2113. +  # Use @e initially of -e because GNU echo has a -e option.
  2114. +  file_substs=`sed -n \
  2115. +"/^ac_include/s%ac_include[     ]*\(.*\)%@e '\\\\\@^&@r \1' -e '\\\\\@^&@d'%p"\
  2116. +               $ac_given_srcdir/${ac_file}.in`
  2117. +  if test -n "$file_substs"; then
  2118. +    # Change @e back to -e.
  2119. +    file_subst_cmd="sed `echo $file_substs | sed s/@e/-e/g`"
  2120. +  else
  2121. +    # If no substitutions and hence no sed commands, don't choke.
  2122. +    file_subst_cmd=cat
  2123. +  fi
  2124. +  # cd into the srcdir because the files being included more or less
  2125. +  # must be part of the distribution. I can't find any way to do
  2126. +  # variable substitution in the sed commands (so the user could have,
  2127. +  # e.g., $top_srcdir in their ac_include line).
  2128. +  (cd $ac_given_srcdir && eval $file_subst_cmd ${ac_file}.in) \
  2129. +  | sed -e "
  2130. +$ac_prsub
  2131. +$ac_vpsub
  2132. +$extrasub
  2133. +s%@CC@%$CC%g
  2134. +s%@CPP@%$CPP%g
  2135. +s%@INSTALL@%$INSTALL%g
  2136. +s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  2137. +s%@INSTALL_DATA@%$INSTALL_DATA%g
  2138. +s%@RANLIB@%$RANLIB%g
  2139. +s%@YACC@%$YACC%g
  2140. +s%@LEX@%$LEX%g
  2141. +s%@LEXLIB@%$LEXLIB%g
  2142. +s%@LN_S@%$LN_S%g
  2143. +s%@LEX_OUTPUT_ROOT@%$LEX_OUTPUT_ROOT%g
  2144. +s%@X_CFLAGS@%$X_CFLAGS%g
  2145. +s%@X_LIBS@%$X_LIBS%g
  2146. +s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
  2147. +s%@wlibs@%$wlibs%g
  2148. +s%@LIBS@%$LIBS%g
  2149. +s%@srcdir@%$srcdir%g
  2150. +s%@top_srcdir@%$top_srcdir%g
  2151. +s%@prefix@%$prefix%g
  2152. +s%@exec_prefix@%$exec_prefix%g
  2153. +s%@DEFS@%-DHAVE_CONFIG_H%" >> $ac_file
  2154. +fi; done
  2155. +
  2156. +# These sed commands are put into ac_sed_defs when defining a macro.
  2157. +# They are broken into pieces to make the sed script easier to manage.
  2158. +# They are passed to sed as "A NAME B NAME C VALUE D", where NAME
  2159. +# is the cpp macro being defined and VALUE is the value it is being given.
  2160. +# Each defining turns into a single global substitution command.
  2161. +# Hopefully no one uses "!" as a variable value.
  2162. +# Other candidates for the sed separators, like , and @, do get used.
  2163. +#
  2164. +# ac_d sets the value in "#define NAME VALUE" lines.
  2165. +ac_dA='s!^\([     ]*\)#\([     ]*define[     ][     ]*\)'
  2166. +ac_dB='\([     ][     ]*\)[^     ]*!\1#\2'
  2167. +ac_dC='\3'
  2168. +ac_dD='!g'
  2169. +# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  2170. +ac_uA='s!^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  2171. +ac_uB='\([     ]\)!\1#\2define\3'
  2172. +ac_uC=' '
  2173. +ac_uD='\4!g'
  2174. +# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  2175. +ac_eA='s!^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  2176. +ac_eB='$!\1#\2define\3'
  2177. +ac_eC=' '
  2178. +ac_eD='!g'
  2179. +rm -f conftest.sed
  2180. +EOF
  2181. +# Turn off quoting long enough to insert the sed commands.
  2182. +rm -f conftest.sh
  2183. +cat > conftest.sh <<EOF
  2184. +$ac_sed_defs
  2185. +EOF
  2186. +
  2187. +# Break up $ac_sed_defs (now in conftest.sh) because some shells have a limit
  2188. +# on the size of here documents.
  2189. +
  2190. +# Maximum number of lines to put in a single here document.
  2191. +ac_max_sh_lines=9
  2192. +
  2193. +while :
  2194. +do
  2195. +  # wc gives bogus results for an empty file on some AIX systems.
  2196. +  ac_lines=`grep -c . conftest.sh`
  2197. +  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  2198. +  rm -f conftest.s1 conftest.s2
  2199. +  sed ${ac_max_sh_lines}q conftest.sh > conftest.s1 # Like head -9.
  2200. +  sed 1,${ac_max_sh_lines}d conftest.sh > conftest.s2 # Like tail +10.
  2201. +  # Write a limited-size here document to append to conftest.sed.
  2202. +  echo 'cat >> conftest.sed <<CONFEOF' >> config.status
  2203. +  cat conftest.s1 >> config.status
  2204. +  echo 'CONFEOF' >> config.status
  2205. +  rm -f conftest.s1 conftest.sh
  2206. +  mv conftest.s2 conftest.sh
  2207. +done
  2208. +rm -f conftest.sh
  2209. +
  2210. +# Now back to your regularly scheduled config.status.
  2211. +cat >> config.status <<\EOF
  2212. +# This sed command replaces #undef's with comments.  This is necessary, for
  2213. +# example, in the case of _POSIX_SOURCE, which is predefined and required
  2214. +# on some systems where configure will not decide to define it in
  2215. +# lib/c-auto.h.
  2216. +cat >> conftest.sed <<\CONFEOF
  2217. +s,^[     ]*#[     ]*undef[     ][     ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
  2218. +CONFEOF
  2219. +rm -f conftest.h
  2220. +# Break up the sed commands because old seds have small limits.
  2221. +ac_max_sed_lines=20
  2222. +
  2223. +CONFIG_HEADERS=${CONFIG_HEADERS-"lib/c-auto.h"}
  2224. +for ac_file in .. ${CONFIG_HEADERS}; do if test "x$ac_file" != x..; then
  2225. +  echo creating $ac_file
  2226. +
  2227. +  cp $ac_given_srcdir/$ac_file.in conftest.h1
  2228. +  cp conftest.sed conftest.stm
  2229. +  while :
  2230. +  do
  2231. +    ac_lines=`grep -c . conftest.stm`
  2232. +    if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  2233. +    rm -f conftest.s1 conftest.s2 conftest.h2
  2234. +    sed ${ac_max_sed_lines}q conftest.stm > conftest.s1 # Like head -20.
  2235. +    sed 1,${ac_max_sed_lines}d conftest.stm > conftest.s2 # Like tail +21.
  2236. +    sed -f conftest.s1 < conftest.h1 > conftest.h2
  2237. +    rm -f conftest.s1 conftest.h1 conftest.stm
  2238. +    mv conftest.h2 conftest.h1
  2239. +    mv conftest.s2 conftest.stm
  2240. +  done
  2241. +  rm -f conftest.stm conftest.h
  2242. +  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  2243. +  cat conftest.h1 >> conftest.h
  2244. +  rm -f conftest.h1
  2245. +  if cmp -s $ac_file conftest.h 2>/dev/null; then
  2246. +    # The file exists and we would not be changing it.
  2247. +    echo "$ac_file is unchanged"
  2248. +    rm -f conftest.h
  2249. +  else
  2250. +    rm -f $ac_file
  2251. +    mv conftest.h $ac_file
  2252. +  fi
  2253. +fi; done
  2254. +rm -f conftest.sed
  2255. +
  2256. +
  2257. +
  2258. +exit 0
  2259. +EOF
  2260. +chmod +x config.status
  2261. +# Some shells look in PATH for config.status without the "./".
  2262. +test -n "$no_create" || ${CONFIG_SHELL-/bin/sh} ./config.status
  2263. +
  2264. diff -Pu2r web2c-6.1a/web2c/lib/c-auto.h.in web2c-6.1b/web2c/lib/c-auto.h.in
  2265. --- web2c-6.1a/web2c/lib/c-auto.h.in    Tue Feb  1 12:28:36 1994
  2266. +++ web2c-6.1b/web2c/lib/c-auto.h.in    Fri Sep 23 18:28:15 1994
  2267. @@ -152,5 +152,10 @@
  2268.  
  2269.  /* Define as the proper declaration for yytext.  */
  2270. -#undef DECLARE_YYTEXT
  2271. +#undef YYTEXT_POINTER
  2272. +#if YYTEXT_POINTER
  2273. +#define DECLARE_YYTEXT extern char *yytext;
  2274. +#else
  2275. +#define DECLARE_YYTEXT extern char yytext[];
  2276. +#endif
  2277.  
  2278.  /* Define if you have dirent.h.  */
  2279. diff -Pu2r web2c-6.1a/web2c/lib/main.c web2c-6.1b/web2c/lib/main.c
  2280. --- web2c-6.1a/web2c/lib/main.c    Tue May 25 11:41:19 1993
  2281. +++ web2c-6.1b/web2c/lib/main.c    Fri Sep 23 15:48:40 1994
  2282. @@ -28,4 +28,5 @@
  2283.    argc = ac;
  2284.    gargv = av;
  2285. +  kpse_set_progname(av[0]);
  2286.    main_body ();
  2287.    return EXIT_SUCCESS;
  2288. diff -Pu2r web2c-6.1a/web2c/lib/ourpaths.c web2c-6.1b/web2c/lib/ourpaths.c
  2289. --- web2c-6.1a/web2c/lib/ourpaths.c    Sun Dec  5 12:48:44 1993
  2290. +++ web2c-6.1b/web2c/lib/ourpaths.c    Fri Sep 23 21:29:51 1994
  2291. @@ -3,9 +3,9 @@
  2292.  #include "config.h"
  2293.  
  2294. -#include <kpathsea/filefmt.h>
  2295. +#include <kpathsea/paths.h>
  2296. +#include <kpathsea/tex-file.h>
  2297.  #include <kpathsea/fontmap.h>
  2298.  #include <kpathsea/pathsearch.h>
  2299.  
  2300. -
  2301.  /* `path_dirs' is initialized in `setpaths', to a null-terminated array
  2302.     of directories to search for.  */
  2303. @@ -23,38 +23,38 @@
  2304.  {
  2305.    if (path_bits & BIBINPUTPATHBIT)
  2306. -    path_dirs[BIBINPUTPATH] = KPSE_BIB_PATH ();
  2307. +    path_dirs[BIBINPUTPATH] = DEFAULT_BIBINPUTS;
  2308.  
  2309.    if (path_bits & BSTINPUTPATHBIT)
  2310. -    path_dirs[BSTINPUTPATH] = KPSE_BST_PATH ();
  2311. +    path_dirs[BSTINPUTPATH] = DEFAULT_BSTINPUTS;
  2312.  
  2313.    if (path_bits & GFFILEPATHBIT)
  2314. -    path_dirs[GFFILEPATH] = KPSE_GF_PATH ();
  2315. +    path_dirs[GFFILEPATH] = DEFAULT_GFFONTS;
  2316.  
  2317.    if (path_bits & MFBASEPATHBIT)
  2318. -    path_dirs[MFBASEPATH] = KPSE_BASE_PATH ();
  2319. +    path_dirs[MFBASEPATH] = DEFAULT_MFBASES;
  2320.  
  2321.    if (path_bits & MFINPUTPATHBIT)
  2322. -    path_dirs[MFINPUTPATH] = KPSE_MF_PATH ();
  2323. +    path_dirs[MFINPUTPATH] = DEFAULT_MFINPUTS;
  2324.  
  2325.    if (path_bits & MFPOOLPATHBIT)
  2326. -    path_dirs[MFPOOLPATH] = KPSE_MFPOOL_PATH ();
  2327. +    path_dirs[MFPOOLPATH] = DEFAULT_MFPOOL;
  2328.  
  2329.    if (path_bits & PKFILEPATHBIT)
  2330. -    path_dirs[PKFILEPATH] = KPSE_PK_PATH ();
  2331. +    path_dirs[PKFILEPATH] = DEFAULT_PKFONTS;
  2332.  
  2333.    if (path_bits & TEXFORMATPATHBIT)
  2334. -    path_dirs[TEXFORMATPATH] = KPSE_FMT_PATH ();
  2335. +    path_dirs[TEXFORMATPATH] = DEFAULT_TEXFORMATS;
  2336.  
  2337.    if (path_bits & TEXINPUTPATHBIT)
  2338. -    path_dirs[TEXINPUTPATH] = KPSE_TEX_PATH ();
  2339. +    path_dirs[TEXINPUTPATH] = DEFAULT_TEXINPUTS;
  2340.  
  2341.    if (path_bits & TEXPOOLPATHBIT)
  2342. -    path_dirs[TEXPOOLPATH] = KPSE_TEXPOOL_PATH ();
  2343. +    path_dirs[TEXPOOLPATH] = DEFAULT_TEXPOOL;
  2344.  
  2345.    if (path_bits & TFMFILEPATHBIT)
  2346. -    path_dirs[TFMFILEPATH] = KPSE_TFM_PATH ();
  2347. +    path_dirs[TFMFILEPATH] = DEFAULT_TFMFONTS;
  2348.  
  2349.    if (path_bits & VFFILEPATHBIT)
  2350. -    path_dirs[VFFILEPATH] = KPSE_VF_PATH ();
  2351. +    path_dirs[VFFILEPATH] = DEFAULT_VFFONTS;
  2352.  }
  2353.  
  2354. @@ -79,5 +79,5 @@
  2355.       have the dpi available separately, and anyway we don't care about
  2356.       having pktogf run MakeTeXPK, etc.  */
  2357. -  found = kpse_path_search (path, name);
  2358. +  found = kpse_path_search (path, name, true);
  2359.  
  2360.    /* If we didn't find it, and we're looking for a font, maybe it's
  2361. @@ -89,8 +89,8 @@
  2362.      {
  2363.        string *mapped_names;
  2364. -      static map_type fontmap = NULL;
  2365. +      static hash_table_type fontmap = { NULL, 0 };
  2366.        
  2367.        /* Fault in the mapping if necessary.  */
  2368. -      if (!fontmap)
  2369. +      if (fontmap.size == 0)
  2370.          fontmap = map_create (path);
  2371.        
  2372. @@ -102,5 +102,5 @@
  2373.            while ((mapped_name = *mapped_names++) && !found)
  2374.              {
  2375. -              found = kpse_path_search (path, mapped_name);
  2376. +              found = kpse_path_search (path, mapped_name, true);
  2377.              }
  2378.          }
  2379. diff -Pu2r web2c-6.1a/web2c/lib/texmf.c web2c-6.1b/web2c/lib/texmf.c
  2380. --- web2c-6.1a/web2c/lib/texmf.c    Sun Dec  5 12:53:01 1993
  2381. +++ web2c-6.1b/web2c/lib/texmf.c    Fri Sep 23 22:33:56 1994
  2382. @@ -33,5 +33,5 @@
  2383.  #include <kpathsea/c-ctype.h>
  2384.  #include <kpathsea/c-pathch.h>
  2385. -#include <kpathsea/tex-make.h>
  2386. +#include <kpathsea/tex-file.h>
  2387.  
  2388.  /* For `struct tm'.  */
  2389. @@ -74,4 +74,6 @@
  2390.    dump_default_length = strlen (dump_default + 1);
  2391.  
  2392. +  kpse_set_progname(av[0]);
  2393. +
  2394.  #ifndef INI
  2395.    if (readyalready != 314159)
  2396. @@ -99,5 +101,5 @@
  2397.                              || getenv ("USE_MAKETEXMF")
  2398.                              || getenv ("MAKETEXMF");
  2399. -    KPSE_MAKE_SPEC_ENABLED (kpse_make_specs[kpse_mf_format]) = use_maketexmf;
  2400. +    kpse_format_info[kpse_mf_format].program_enabled_p = use_maketexmf;
  2401.    }
  2402.  #endif /* MF */
  2403. @@ -110,6 +112,6 @@
  2404.                               || getenv ("USE_MAKETEXTFM")
  2405.                               || getenv ("MAKETEXTFM");
  2406. -    KPSE_MAKE_SPEC_ENABLED (kpse_make_specs[kpse_tex_format]) = use_maketextex;
  2407. -    KPSE_MAKE_SPEC_ENABLED (kpse_make_specs[kpse_tfm_format]) = use_maketextfm;
  2408. +    kpse_format_info[kpse_tex_format].program_enabled_p = use_maketextex;
  2409. +    kpse_format_info[kpse_tfm_format].program_enabled_p = use_maketextfm;
  2410.    }
  2411.  #endif /* TeX */
  2412. diff -Pu2r web2c-6.1a/web2c/mf/Makefile.in web2c-6.1b/web2c/mf/Makefile.in
  2413. --- web2c-6.1a/web2c/mf/Makefile.in    Thu Feb  3 04:48:35 1994
  2414. +++ web2c-6.1b/web2c/mf/Makefile.in    Sat Sep 24 02:08:29 1994
  2415. @@ -46,7 +46,7 @@
  2416.  libs = $(commono) $(LIBS)
  2417.  
  2418. -x_include_flags = @x_include_flags@
  2419. -x_lib_flags = @x_lib_flags@
  2420. -x_extra_libs = @x_extra_libs@
  2421. +x_include_flags = @X_CFLAGS@
  2422. +x_lib_flags = @X_LIBS@
  2423. +x_extra_libs = @X_EXTRA_LIBS@
  2424.  wlibs = @wlibs@
  2425.  LIBS = @LIBS@
  2426. @@ -72,6 +72,5 @@
  2427.  # What to pass to submakes.
  2428.  makeargs=SHELL='$(SHELL)' CC='$(CC)' CFLAGS='$(CFLAGS)' \
  2429. -LDFLAGS='$(LDFLAGS)' LIBS='$(libs)' RANLIB='$(RANLIB)' LN='$(LN)' \
  2430. -srcdir=$(srcdir)  
  2431. +LDFLAGS='$(LDFLAGS)' LIBS='$(libs)' RANLIB='$(RANLIB)' LN='$(LN)'
  2432.  
  2433.